-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathGUI.py
66 lines (45 loc) · 1.39 KB
/
GUI.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
import os
from PyQt4 import *
from PyQt4 import QtCore, QtGui
from PyQt4.QtGui import QFileDialog, QStringListModel
import errno
import sys
try:
_fromUtf8 = QtCore.QString.fromUtf8
except AttributeError:
def _fromUtf8(s):
return s
try:
_encoding = QtGui.QApplication.UnicodeUTF8
def _translate(context, text, disambig):
return QtGui.QApplication.translate(context, text, disambig, _encoding)
except AttributeError:
def _translate(context, text, disambig):
return QtGui.QApplication.translate(context, text, disambig)
class Ui_Home(object):
def setupUi(self, Dialog):
self.openedlist = []
Dialog.setObjectName(_fromUtf8("Dialog"))
self.dialog = Dialog
self.dialog.setWindowIcon(QtGui.QIcon('ico.png'))
Dialog.resize(635, 342)
self.retranslateUi(Dialog)
QtCore.QMetaObject.connectSlotsByName(Dialog)
def retranslateUi(self, Dialog):
Dialog.setWindowTitle(_translate("Dialog", "Wetspa_Urban", None))
def make_sure_path_exists(path):
try:
os.makedirs(path)
except OSError as exception:
if exception.errno != errno.EEXIST:
raise
def main():
sys.setrecursionlimit(10 ** 6)
app = QtGui.QApplication(sys.argv)
Dialog = QtGui.QDialog()
ui = Ui_Home()
ui.setupUi(Dialog)
Dialog.show()
(app.exec_())
if __name__ == "__main__":
main()