UI/UserInterface.py

changeset 4630
7b0e38956b5c
parent 4629
99aaac59be4f
child 4631
5c1a96925da4
equal deleted inserted replaced
4629:99aaac59be4f 4630:7b0e38956b5c
132 @signal reloadAPIs() emitted to reload the api information 132 @signal reloadAPIs() emitted to reload the api information
133 @signal showMenu(str, QMenu) emitted when a menu is about to be shown. The 133 @signal showMenu(str, QMenu) emitted when a menu is about to be shown. The
134 name of the menu and a reference to the menu are given. 134 name of the menu and a reference to the menu are given.
135 @signal masterPasswordChanged(str, str) emitted after the master 135 @signal masterPasswordChanged(str, str) emitted after the master
136 password has been changed with the old and the new password 136 password has been changed with the old and the new password
137 @signal onlineStateChanged(online) emitted to indicate a change of the
138 network state
137 """ 139 """
138 appendStderr = pyqtSignal(str) 140 appendStderr = pyqtSignal(str)
139 appendStdout = pyqtSignal(str) 141 appendStdout = pyqtSignal(str)
140 preferencesChanged = pyqtSignal() 142 preferencesChanged = pyqtSignal()
141 reloadAPIs = pyqtSignal() 143 reloadAPIs = pyqtSignal()
142 showMenu = pyqtSignal(str, QMenu) 144 showMenu = pyqtSignal(str, QMenu)
143 masterPasswordChanged = pyqtSignal(str, str) 145 masterPasswordChanged = pyqtSignal(str, str)
146 onlineStateChanged = pyqtSignal(bool)
144 147
145 maxFilePathLen = 100 148 maxFilePathLen = 100
146 maxMenuFilePathLen = 75 149 maxMenuFilePathLen = 75
147 150
148 LeftSide = 1 151 LeftSide = 1
2820 self.sbVcsMonitorLed = StatusMonitorLed(self.project, self.__statusBar) 2823 self.sbVcsMonitorLed = StatusMonitorLed(self.project, self.__statusBar)
2821 self.__statusBar.addPermanentWidget(self.sbVcsMonitorLed) 2824 self.__statusBar.addPermanentWidget(self.sbVcsMonitorLed)
2822 2825
2823 self.networkIcon = E5NetworkIcon(self.__statusBar) 2826 self.networkIcon = E5NetworkIcon(self.__statusBar)
2824 self.__statusBar.addPermanentWidget(self.networkIcon) 2827 self.__statusBar.addPermanentWidget(self.networkIcon)
2828 self.networkIcon.onlineStateChanged.connect(self.onlineStateChanged)
2829 self.networkIcon.onlineStateChanged.connect(self.__onlineStateChanged)
2825 2830
2826 def __initExternalToolsActions(self): 2831 def __initExternalToolsActions(self):
2827 """ 2832 """
2828 Private slot to create actions for the configured external tools. 2833 Private slot to create actions for the configured external tools.
2829 """ 2834 """
5792 5797
5793 def checkPluginUpdatesAvailable(self): 5798 def checkPluginUpdatesAvailable(self):
5794 """ 5799 """
5795 Public method to check the availability of updates of plug-ins. 5800 Public method to check the availability of updates of plug-ins.
5796 """ 5801 """
5797 self.pluginManager.checkPluginUpdatesAvailable() 5802 if self.isOnline():
5803 self.pluginManager.checkPluginUpdatesAvailable()
5798 5804
5799 ################################################################# 5805 #################################################################
5800 ## Drag and Drop Support 5806 ## Drag and Drop Support
5801 ################################################################# 5807 #################################################################
5802 5808
5942 5948
5943 @return online state 5949 @return online state
5944 @rtype bool 5950 @rtype bool
5945 """ 5951 """
5946 return self.networkIcon.isOnline() 5952 return self.networkIcon.isOnline()
5953
5954 def __onlineStateChanged(self, online):
5955 """
5956 Private slot handling changes in online state.
5957
5958 @param online flag indicating the online state
5959 @type bool
5960 """
5961 if online:
5962 self.performVersionCheck(False)
5947 5963
5948 ############################################## 5964 ##############################################
5949 ## Below are methods to check for new versions 5965 ## Below are methods to check for new versions
5950 ############################################## 5966 ##############################################
5951 5967

eric ide

mercurial