eric7/WebBrowser/AdBlock/AdBlockIcon.py

branch
eric7
changeset 8318
962bce857696
parent 8312
800c432b34c8
child 8345
b2e19966263a
diff -r 0c7a44af84bc -r 962bce857696 eric7/WebBrowser/AdBlock/AdBlockIcon.py
--- a/eric7/WebBrowser/AdBlock/AdBlockIcon.py	Sun May 16 11:43:59 2021 +0200
+++ b/eric7/WebBrowser/AdBlock/AdBlockIcon.py	Sun May 16 20:07:24 2021 +0200
@@ -7,8 +7,9 @@
 Module implementing the AdBlock icon for the main window status bar.
 """
 
-from PyQt5.QtCore import Qt
-from PyQt5.QtWidgets import QAction, QMenu
+from PyQt6.QtCore import Qt
+from PyQt6.QtGui import QAction
+from PyQt6.QtWidgets import QMenu
 
 from E5Gui.E5ClickableLabel import E5ClickableLabel
 
@@ -94,6 +95,7 @@
             UI.PixmapCache.getIcon("adBlockPlus"),
             self.tr("AdBlock Configuration..."), manager.showDialog)
     
+    # TODO: change this to return a QMenu
     def menuAction(self):
         """
         Public method to get a reference to the menu action.
@@ -103,6 +105,7 @@
         """
         if not self.__menuAction:
             self.__menuAction = QAction(self.tr("AdBlock"), self)
+            # TODO: replace this obsolete function
             self.__menuAction.setMenu(QMenu())
             self.__menuAction.menu().aboutToShow.connect(
                 lambda: self.__createMenu(self.__menuAction.menu()))

eric ide

mercurial