##// END OF EJS Templates
Adicion de Icono...
Alexander Valdez -
r365:fb193e013596
parent child
Show More
@@ -1,70 +1,63
1 # -*- coding: utf-8 -*-
1 # -*- coding: utf-8 -*-
2
2
3 from PyQt4.QtGui import QMainWindow
3 from PyQt4.QtGui import QMainWindow
4 from PyQt4.QtCore import pyqtSignature
4 from PyQt4.QtCore import pyqtSignature
5 from PyQt4.QtCore import pyqtSignal
5 from PyQt4.QtCore import pyqtSignal
6 from PyQt4 import QtGui
6 from PyQt4 import QtGui
7 from viewcontroller.mainwindow import MainWindow
8 from viewer.ui_workspace import Ui_Workspace
7 from viewer.ui_workspace import Ui_Workspace
9
8
10 class Workspace(QMainWindow, Ui_Workspace):
9 class Workspace(QMainWindow, Ui_Workspace):
11 """
10 """
12 Class documentation goes here.
11 Class documentation goes here.
13 """
12 """
14 closed=pyqtSignal()
13 closed=pyqtSignal()
15 def __init__(self, parent = None):
14 def __init__(self, parent = None):
16 """
15 """
17 Constructor
16 Constructor
18 """
17 """
19 QMainWindow.__init__(self, parent)
18 QMainWindow.__init__(self, parent)
20 self.dirList=[]
19 self.dirList=[]
21 self.setupUi(self)
20 self.setupUi(self)
21 self.setWindowTitle("ROJ-Signal Chain")
22 self.setWindowIcon(QtGui.QIcon("figure/adn.jpg"))
22 #*####### DIRECTORIO DE TRABAJO #########*#
23 #*####### DIRECTORIO DE TRABAJO #########*#
23 self.dirCmbBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "C:\WorkSpaceGui", None, QtGui.QApplication.UnicodeUTF8))
24 #self.dirCmbBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "C:\WorkSpaceGui", None, QtGui.QApplication.UnicodeUTF8))
25
24 self.dir=str("C:\WorkSpaceGui")
26 self.dir=str("C:\WorkSpaceGui")
25 self.dirCmbBox.addItem(self.dir)
27 self.dirComBox.addItem(self.dir)
26 self.dirList.append(self.dir)
28 self.i=0
29
27
30
28 @pyqtSignature("")
31 @pyqtSignature("")
29 def on_dirBrowsebtn_clicked(self):
32 def on_dirToolPath_clicked(self):
30 """
33 """
31 Slot documentation goes here.
34 Slot documentation goes here.
32 """
35 """
33
36 self.i +=1
34 self.dirBrowse = str(QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly))
37 self.dirBrowse = str(QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly))
35 self.dirCmbBox.setItemText(0, QtGui.QApplication.translate("MainWindow", self.dirBrowse, None, QtGui.QApplication.UnicodeUTF8))
38 self.dirComBox.addItem(self.dirBrowse)
36 self.dirList.append(self.dirBrowse)
39 self.dirComBox.setCurrentIndex(self.i)
37 self.dirCmbBox.clear()
38 for i in self.dirList:
39 self.dirCmbBox.addItem(i)
40
41
40
42
41
43 @pyqtSignature("")
44 def on_dirButton_clicked(self):
45 """
46 Slot documentation goes here.
47 """
48 pass
49
42
50 @pyqtSignature("")
43 @pyqtSignature("")
51 def on_dirOkbtn_clicked(self):
44 def on_dirOkBtn_clicked(self):
52 """
45 """
53 VISTA DE INTERFAZ GRÁFICA
46 VISTA DE INTERFAZ GRÁFICA
54 """
47 """
55 self.close()
48 self.close()
56
49
57 @pyqtSignature("")
50 @pyqtSignature("")
58 def on_dirCancelbtn_clicked(self):
51 def on_dirCancelBtn_clicked(self):
59 """
52 """
60 Cerrar
53 Cerrar
61 """
54 """
62 self.close()
55 self.close()
63
56
64 def closeEvent(self, event):
57 def closeEvent(self, event):
65 self.closed.emit()
58 self.closed.emit()
66 event.accept()
59 event.accept()
67
60
68
61
69
62
70 No newline at end of file
63
General Comments 0
You need to be logged in to leave comments. Login now