# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file '/home/detlev/Development/Python/Eric/eric3/Project/AddFileForm.ui'
#
# Created: Mon Jan 20 20:44:55 2003
# by: The PyQt User Interface Compiler (pyuic)
#
# WARNING! All changes made in this file will be lost!
import sys
from qt import *
class AddFileForm(QDialog):
def __init__(self,parent = None,name = None,modal = 0,fl = 0):
QDialog.__init__(self,parent,name,modal,fl)
if not name:
self.setName("AddFileForm")
AddFileFormLayout = QVBoxLayout(self,6,6,"AddFileFormLayout")
Layout6 = QGridLayout(None,1,1,0,6,"Layout6")
self.sourceFileButton = QPushButton(self,"sourceFileButton")
Layout6.addWidget(self.sourceFileButton,0,2)
self.targetDirLabel = QLabel(self,"targetDirLabel")
Layout6.addWidget(self.targetDirLabel,1,0)
self.targetDirEdit = QLineEdit(self,"targetDirEdit")
Layout6.addWidget(self.targetDirEdit,1,1)
self.targetDirButton = QPushButton(self,"targetDirButton")
Layout6.addWidget(self.targetDirButton,1,2)
self.sourceFileLabel = QLabel(self,"sourceFileLabel")
Layout6.addWidget(self.sourceFileLabel,0,0)
self.sourceFileEdit = QLineEdit(self,"sourceFileEdit")
Layout6.addWidget(self.sourceFileEdit,0,1)
AddFileFormLayout.addLayout(Layout6)
Layout5 = QHBoxLayout(None,0,6,"Layout5")
spacer = QSpacerItem(30,0,QSizePolicy.Expanding,QSizePolicy.Minimum)
Layout5.addItem(spacer)
self.okButton = QPushButton(self,"okButton")
self.okButton.setDefault(1)
Layout5.addWidget(self.okButton)
self.cancelButton = QPushButton(self,"cancelButton")
Layout5.addWidget(self.cancelButton)
spacer_2 = QSpacerItem(30,0,QSizePolicy.Expanding,QSizePolicy.Minimum)
Layout5.addItem(spacer_2)
AddFileFormLayout.addLayout(Layout5)
self.languageChange()
self.resize(QSize(391,109).expandedTo(self.minimumSizeHint()))
self.connect(self.okButton,SIGNAL("clicked()"),self,SLOT("accept()"))
self.connect(self.cancelButton,SIGNAL("clicked()"),self,SLOT("reject()"))
self.connect(self.sourceFileButton,SIGNAL("clicked()"),self.handleFileDialog)
self.connect(self.targetDirButton,SIGNAL("clicked()"),self.handleDirDialog)
self.connect(self.sourceFileEdit,SIGNAL("textChanged(const QString&)"),self.handleSTextChanged)
self.setTabOrder(self.sourceFileEdit,self.sourceFileButton)
self.setTabOrder(self.sourceFileButton,self.targetDirEdit)
self.setTabOrder(self.targetDirEdit,self.targetDirButton)
self.setTabOrder(self.targetDirButton,self.okButton)
self.setTabOrder(self.okButton,self.cancelButton)
self.targetDirLabel.setBuddy(self.targetDirEdit)
self.sourceFileLabel.setBuddy(self.sourceFileEdit)
def languageChange(self):
self.setCaption(self.tr("Add File"))
QToolTip.add(self,self.tr("Add a file to the current project"))
QWhatsThis.add(self,self.tr("<b>Add File Dialog</b>\n"
"<p>This dialog is used to add a file to the current project.</p>"))
self.sourceFileButton.setText(self.tr("..."))
self.targetDirLabel.setText(self.tr("&Target Directory:"))
QToolTip.add(self.targetDirEdit,self.tr("Enter the target directory for the file"))
QWhatsThis.add(self.targetDirEdit,self.tr("<b>Target Directory</b>\n"
"<p>Enter the target directory. You may select it\n"
" with a dialog by pressing the button to the right.</p>"))
self.targetDirButton.setText(self.tr("..."))
QWhatsThis.add(self.targetDirButton,self.tr("<b>Target Directory</b>\n"
"<p>Select the target directory via a directory selection dialog.</p>"))
self.sourceFileLabel.setText(self.tr("&Source File:"))
QToolTip.add(self.sourceFileEdit,self.tr("Enter the name of the file to add"))
QWhatsThis.add(self.sourceFileEdit,self.tr("<b>Source File</b>\n"
"<p>Enter the name of the file to add to the current project.\n"
" You may select it with a dialog by pressing the button to\n"
" the right.</p>"))
self.okButton.setText(self.tr("&OK"))
self.cancelButton.setText(self.tr("&Cancel"))
def handleDirDialog(self):
print "AddFileForm.handleDirDialog(): Not implemented yet"
def handleFileDialog(self):
print "AddFileForm.handleFileDialog(): Not implemented yet"
def handleSTextChanged(self,a0):
print "AddFileForm.handleSTextChanged(const QString&): Not implemented yet"
if __name__ == "__main__":
a = QApplication(sys.argv)
QObject.connect(a,SIGNAL("lastWindowClosed()"),a,SLOT("quit()"))
w = AddFileForm()
a.setMainWidget(w)
w.show()
a.exec_loop()
|