src/eric7/WebBrowser/Navigation/ReloadStopButton.py

branch
eric7
changeset 9413
80c06d472826
parent 9221
bf71ee032bb4
child 9473
3f23dbf37dbe
equal deleted inserted replaced
9412:45e7bb09c120 9413:80c06d472826
7 Module implementing a button alternating between reload and stop. 7 Module implementing a button alternating between reload and stop.
8 """ 8 """
9 9
10 from PyQt6.QtCore import pyqtSlot, pyqtSignal, Qt 10 from PyQt6.QtCore import pyqtSlot, pyqtSignal, Qt
11 11
12 from EricWidgets.EricToolButton import EricToolButton 12 from eric7.EricWidgets.EricToolButton import EricToolButton
13 13
14 import UI.PixmapCache 14 from eric7.EricGui import EricPixmapCache
15 15
16 16
17 class ReloadStopButton(EricToolButton): 17 class ReloadStopButton(EricToolButton):
18 """ 18 """
19 Class implementing a button alternating between reload and stop. 19 Class implementing a button alternating between reload and stop.
59 def __updateButton(self): 59 def __updateButton(self):
60 """ 60 """
61 Private slot to update the button. 61 Private slot to update the button.
62 """ 62 """
63 if self.__loading: 63 if self.__loading:
64 self.setIcon(UI.PixmapCache.getIcon("stopLoading")) 64 self.setIcon(EricPixmapCache.getIcon("stopLoading"))
65 self.setToolTip(self.tr("Stop loading")) 65 self.setToolTip(self.tr("Stop loading"))
66 else: 66 else:
67 self.setIcon(UI.PixmapCache.getIcon("reload")) 67 self.setIcon(EricPixmapCache.getIcon("reload"))
68 self.setToolTip(self.tr("Reload the current screen")) 68 self.setToolTip(self.tr("Reload the current screen"))
69 69
70 def setLoading(self, loading): 70 def setLoading(self, loading):
71 """ 71 """
72 Public method to set the loading state. 72 Public method to set the loading state.

eric ide

mercurial