14 pass |
14 pass |
15 |
15 |
16 import os |
16 import os |
17 import re |
17 import re |
18 |
18 |
19 from PyQt4.QtCore import pyqtSlot, Qt, QProcess |
19 from PyQt5.QtCore import pyqtSlot, Qt, QProcess |
20 from PyQt4.QtGui import QApplication, QTreeWidgetItem, QHeaderView, QCursor, \ |
20 from PyQt5.QtGui import QCursor |
|
21 from PyQt5.QtWidgets import QApplication, QTreeWidgetItem, QHeaderView, \ |
21 QDialog, QDialogButtonBox |
22 QDialog, QDialogButtonBox |
22 |
23 |
23 from E5Gui.E5Application import e5App |
24 from E5Gui.E5Application import e5App |
24 |
25 |
25 from .Ui_ProgramsDialog import Ui_ProgramsDialog |
26 from .Ui_ProgramsDialog import Ui_ProgramsDialog |
130 Utilities.generateQtToolName("assistant")) |
131 Utilities.generateQtToolName("assistant")) |
131 self.__createProgramEntry( |
132 self.__createProgramEntry( |
132 self.tr("Qt Assistant"), exe, version=version) |
133 self.tr("Qt Assistant"), exe, version=version) |
133 |
134 |
134 # 2. do the PyQt programs |
135 # 2. do the PyQt programs |
135 # 2a. Translation Extractor PyQt4 |
136 # 2a. Translation Extractor PyQt5 |
136 self.__createProgramEntry( |
137 self.__createProgramEntry( |
137 self.tr("Translation Extractor (Python, PyQt4)"), |
138 self.tr("Translation Extractor (Python, PyQt5)"), |
138 Utilities.isWindowsPlatform() and "pylupdate4.exe" or "pylupdate4", |
139 Utilities.isWindowsPlatform() and "pylupdate4.exe" or "pylupdate4", |
139 '-version', 'pylupdate', -1) |
140 '-version', 'pylupdate', -1) |
140 # 2b. Forms Compiler PyQt4 |
141 # 2b. Forms Compiler PyQt5 |
141 self.__createProgramEntry( |
142 self.__createProgramEntry( |
142 self.tr("Forms Compiler (Python, PyQt4)"), |
143 self.tr("Forms Compiler (Python, PyQt5)"), |
143 Utilities.isWindowsPlatform() and "pyuic4.bat" or "pyuic4", |
144 Utilities.isWindowsPlatform() and "pyuic4.bat" or "pyuic4", |
144 '--version', 'Python User', 4) |
145 '--version', 'Python User', 4) |
145 # 2c. Resource Compiler PyQt4 |
146 # 2c. Resource Compiler PyQt5 |
146 self.__createProgramEntry( |
147 self.__createProgramEntry( |
147 self.tr("Resource Compiler (Python, PyQt4)"), |
148 self.tr("Resource Compiler (Python, PyQt5)"), |
148 Utilities.isWindowsPlatform() and "pyrcc4.exe" or "pyrcc4", |
149 Utilities.isWindowsPlatform() and "pyrcc4.exe" or "pyrcc4", |
149 '-version', 'Resource Compiler', -1) |
150 '-version', 'Resource Compiler', -1) |
150 # 2d. Translation Extractor PyQt5 |
151 # 2d. Translation Extractor PyQt5 |
151 self.__createProgramEntry( |
152 self.__createProgramEntry( |
152 self.tr("Translation Extractor (Python, PyQt5)"), |
153 self.tr("Translation Extractor (Python, PyQt5)"), |