14 from PyQt6.QtCore import pyqtSlot, Qt, QProcess |
14 from PyQt6.QtCore import pyqtSlot, Qt, QProcess |
15 from PyQt6.QtWidgets import ( |
15 from PyQt6.QtWidgets import ( |
16 QApplication, QTreeWidgetItem, QHeaderView, QDialog, QDialogButtonBox |
16 QApplication, QTreeWidgetItem, QHeaderView, QDialog, QDialogButtonBox |
17 ) |
17 ) |
18 |
18 |
19 from E5Gui.E5Application import e5App |
19 from E5Gui.EricApplication import ericApp |
20 from E5Gui.E5OverrideCursor import E5OverrideCursor |
20 from E5Gui.EricOverrideCursor import EricOverrideCursor |
21 |
21 |
22 from .Ui_ProgramsDialog import Ui_ProgramsDialog |
22 from .Ui_ProgramsDialog import Ui_ProgramsDialog |
23 |
23 |
24 import Preferences |
24 import Preferences |
25 import Utilities |
25 import Utilities |
83 self.programsList.clear() |
83 self.programsList.clear() |
84 header = self.programsList.header() |
84 header = self.programsList.header() |
85 header.setSortIndicator(0, Qt.SortOrder.AscendingOrder) |
85 header.setSortIndicator(0, Qt.SortOrder.AscendingOrder) |
86 header.setSortIndicatorShown(False) |
86 header.setSortIndicatorShown(False) |
87 |
87 |
88 with E5OverrideCursor(): |
88 with EricOverrideCursor(): |
89 # 1. do the Qt programs |
89 # 1. do the Qt programs |
90 # 1a. Translation Converter |
90 # 1a. Translation Converter |
91 exe = ( |
91 exe = ( |
92 Utilities.isWindowsPlatform() and |
92 Utilities.isWindowsPlatform() and |
93 "{0}.exe".format(Utilities.generateQtToolName("lrelease")) or |
93 "{0}.exe".format(Utilities.generateQtToolName("lrelease")) or |
210 exe += ".exe" |
210 exe += ".exe" |
211 self.__createProgramEntry( |
211 self.__createProgramEntry( |
212 self.tr("conda Manager"), exe, '--version', 'conda', -1) |
212 self.tr("conda Manager"), exe, '--version', 'conda', -1) |
213 |
213 |
214 # 5. do the pip program(s) |
214 # 5. do the pip program(s) |
215 virtualenvManager = e5App().getObject("VirtualEnvManager") |
215 virtualenvManager = ericApp().getObject("VirtualEnvManager") |
216 for venvName in virtualenvManager.getVirtualenvNames(): |
216 for venvName in virtualenvManager.getVirtualenvNames(): |
217 interpreter = virtualenvManager.getVirtualenvInterpreter( |
217 interpreter = virtualenvManager.getVirtualenvInterpreter( |
218 venvName) |
218 venvName) |
219 self.__createProgramEntry( |
219 self.__createProgramEntry( |
220 self.tr("PyPI Package Management"), interpreter, |
220 self.tr("PyPI Package Management"), interpreter, |
296 self.__createProgramEntry( |
296 self.__createProgramEntry( |
297 self.tr("MicroPython - PyBoard Flasher"), exe, '--version', |
297 self.tr("MicroPython - PyBoard Flasher"), exe, '--version', |
298 'dfu-util', -1) |
298 'dfu-util', -1) |
299 |
299 |
300 # 10. do the plugin related programs |
300 # 10. do the plugin related programs |
301 pm = e5App().getObject("PluginManager") |
301 pm = ericApp().getObject("PluginManager") |
302 for info in pm.getPluginExeDisplayData(): |
302 for info in pm.getPluginExeDisplayData(): |
303 if info["programEntry"]: |
303 if info["programEntry"]: |
304 if "exeModule" not in info: |
304 if "exeModule" not in info: |
305 info["exeModule"] = None |
305 info["exeModule"] = None |
306 if "versionRe" not in info: |
306 if "versionRe" not in info: |