eric7/MicroPython/PyBoardDevices.py

branch
eric7
changeset 8356
68ec9c3d4de5
parent 8322
b422b4e77d19
child 8358
144a6b854f70
--- a/eric7/MicroPython/PyBoardDevices.py	Sat May 22 17:01:51 2021 +0200
+++ b/eric7/MicroPython/PyBoardDevices.py	Sat May 22 18:51:46 2021 +0200
@@ -11,9 +11,9 @@
 
 from PyQt6.QtCore import pyqtSlot, QStandardPaths
 
-from E5Gui import E5MessageBox, E5FileDialog
-from E5Gui.E5Application import e5App
-from E5Gui.E5ProcessDialog import E5ProcessDialog
+from E5Gui import EricMessageBox, EricFileDialog
+from E5Gui.EricApplication import ericApp
+from E5Gui.EricProcessDialog import EricProcessDialog
 
 from .MicroPythonDevices import MicroPythonDevice
 from .MicroPythonWidget import HAS_QTCHART
@@ -188,7 +188,7 @@
             # return the default workspace and give the user a warning (unless
             # silent mode is selected)
             if not silent:
-                E5MessageBox.warning(
+                EricMessageBox.warning(
                     self.microPython,
                     self.tr("Workspace Directory"),
                     self.tr("Python files for PyBoard can be edited in"
@@ -255,7 +255,7 @@
         Private slot to open the URL containing instructions for installing
         MicroPython on the pyboard.
         """
-        e5App().getObject("UserInterface").launchHelpViewer(
+        ericApp().getObject("UserInterface").launchHelpViewer(
             PyBoardDevice.FlashInstructionsURL)
     
     def __dfuUtilAvailable(self):
@@ -276,7 +276,7 @@
                 available = True
         
         if not available:
-            E5MessageBox.critical(
+            EricMessageBox.critical(
                 self.microPython,
                 self.tr("dfu-util not available"),
                 self.tr("""The dfu-util firmware flashing tool"""
@@ -316,13 +316,13 @@
         msg += self.tr(
             "<p>Press <b>OK</b> to continue...</p>"
         )
-        res = E5MessageBox.information(
+        res = EricMessageBox.information(
             self.microPython,
             self.tr("Enable DFU mode"),
             msg,
-            E5MessageBox.Abort | E5MessageBox.Ok)
+            EricMessageBox.Abort | EricMessageBox.Ok)
         
-        return res == E5MessageBox.Ok
+        return res == EricMessageBox.Ok
     
     def __showDfuDisableInstructions(self):
         """
@@ -336,7 +336,7 @@
             "<hr />"
             "<p>Press <b>OK</b> to continue...</p>"
         )
-        E5MessageBox.information(
+        EricMessageBox.information(
             self.microPython,
             self.tr("Disable DFU mode"),
             msg
@@ -357,7 +357,7 @@
                 args = [
                     "--list",
                 ]
-                dlg = E5ProcessDialog(
+                dlg = EricProcessDialog(
                     self.tr("'dfu-util' Output"),
                     self.tr("List DFU capable Devices")
                 )
@@ -379,7 +379,7 @@
                 
                 downloadsPath = QStandardPaths.standardLocations(
                     QStandardPaths.StandardLocation.DownloadLocation)[0]
-                firmware = E5FileDialog.getOpenFileName(
+                firmware = EricFileDialog.getOpenFileName(
                     self.microPython,
                     self.tr("Flash MicroPython Firmware"),
                     downloadsPath,
@@ -391,7 +391,7 @@
                         "--alt", "0",
                         "--download", firmware,
                     ]
-                    dlg = E5ProcessDialog(
+                    dlg = EricProcessDialog(
                         self.tr("'dfu-util' Output"),
                         self.tr("Flash MicroPython Firmware")
                     )

eric ide

mercurial