diff -r 0a02c433f52d -r 5883ce99ee12 PluginManager/PluginManager.py --- a/PluginManager/PluginManager.py Fri Nov 01 15:48:48 2013 +0100 +++ b/PluginManager/PluginManager.py Sun Nov 03 15:58:22 2013 +0100 @@ -82,7 +82,7 @@ self.pluginDirs = { "eric5": os.path.join(getConfig('ericDir'), "Plugins"), "global": os.path.join(Utilities.getPythonModulesDirectory(), - "eric5plugins"), + "eric5plugins"), "user": os.path.join(Utilities.getConfigDir(), "eric5plugins"), } self.__priorityOrder = ["eric5", "global", "user"] @@ -125,7 +125,7 @@ Public method to finalize the setup of the plugin manager. """ for module in list(self.__onDemandInactiveModules.values()) + \ - list(self.__onDemandActiveModules.values()): + list(self.__onDemandActiveModules.values()): if hasattr(module, "moduleSetup"): module.moduleSetup() @@ -163,7 +163,7 @@ except IOError: return ( False, - self.trUtf8("Could not create a package for {0}.")\ + self.trUtf8("Could not create a package for {0}.") .format(self.__develPluginFile)) if Preferences.getPluginManager("ActivateExternal"): @@ -223,7 +223,7 @@ self.__foundUserModules = \ self.getPluginModules(self.pluginDirs["user"]) - return len(self.__foundCoreModules + self.__foundGlobalModules + \ + return len(self.__foundCoreModules + self.__foundGlobalModules + self.__foundUserModules) > 0 def getPluginModules(self, pluginPath): @@ -233,7 +233,7 @@ @param pluginPath name of the path to search (string) @return list of plugin module names (list of string) """ - pluginFiles = [f[:-3] for f in os.listdir(pluginPath) \ + pluginFiles = [f[:-3] for f in os.listdir(pluginPath) if self.isValidPluginName(f)] return pluginFiles[:] @@ -771,7 +771,7 @@ for name, module in \ list(self.__onDemandActiveModules.items()) + \ - list(self.__onDemandInactiveModules.items()): + list(self.__onDemandInactiveModules.items()): if getattr(module, "pluginType") == type_ and \ getattr(module, "error", "") == "": plugin_name = getattr(module, "pluginTypename") @@ -797,7 +797,7 @@ """ for modname, module in \ list(self.__onDemandActiveModules.items()) + \ - list(self.__onDemandInactiveModules.items()): + list(self.__onDemandInactiveModules.items()): if getattr(module, "pluginType") == type_ and \ getattr(module, "pluginTypename") == name: if hasattr(module, "previewPix"): @@ -817,7 +817,7 @@ apis = [] for module in list(self.__activeModules.values()) + \ - list(self.__onDemandActiveModules.values()): + list(self.__onDemandActiveModules.values()): if hasattr(module, "apiFiles"): apis.extend(module.apiFiles(language)) @@ -860,13 +860,13 @@ infos = [] for module in list(self.__activeModules.values()) + \ - list(self.__inactiveModules.values()): + list(self.__inactiveModules.values()): if hasattr(module, "exeDisplayDataList"): infos.extend(module.exeDisplayDataList()) elif hasattr(module, "exeDisplayData"): infos.append(module.exeDisplayData()) for module in list(self.__onDemandActiveModules.values()) + \ - list(self.__onDemandInactiveModules.values()): + list(self.__onDemandInactiveModules.values()): if hasattr(module, "exeDisplayDataList"): infos.extend(module.exeDisplayDataList()) elif hasattr(module, "exeDisplayData"): @@ -908,8 +908,8 @@ """ configData = {} for module in list(self.__activeModules.values()) + \ - list(self.__onDemandActiveModules.values()) + \ - list(self.__onDemandInactiveModules.values()): + list(self.__onDemandActiveModules.values()) + \ + list(self.__onDemandInactiveModules.values()): if hasattr(module, 'getConfigData'): configData.update(module.getConfigData()) return configData @@ -922,9 +922,9 @@ @return flag indicating, if the plugin is loaded (boolean) """ return pluginName in self.__activeModules or \ - pluginName in self.__inactiveModules or \ - pluginName in self.__onDemandActiveModules or \ - pluginName in self.__onDemandInactiveModules + pluginName in self.__inactiveModules or \ + pluginName in self.__onDemandActiveModules or \ + pluginName in self.__onDemandInactiveModules def isPluginActive(self, pluginName): """ @@ -934,7 +934,7 @@ @return flag indicating, if the plugin is active (boolean) """ return pluginName in self.__activeModules or \ - pluginName in self.__onDemandActiveModules + pluginName in self.__onDemandActiveModules ########################################################################### ## Specialized plugin module handling methods below @@ -960,7 +960,7 @@ for name, module in \ list(self.__onDemandActiveModules.items()) + \ - list(self.__onDemandInactiveModules.items()): + list(self.__onDemandInactiveModules.items()): if getattr(module, "pluginType") == "version_control": if hasattr(module, "getVcsSystemIndicator"): res = module.getVcsSystemIndicator() @@ -1007,7 +1007,7 @@ """ <b>{0}</b> could not be created. Please""" """ configure it via the configuration""" """ dialog.</p><p>Reason: {1}</p>""") - .format(downloadDir, str(err))) + .format(downloadDir, str(err))) downloadDir = "" Preferences.setPluginManager("DownloadPath", downloadDir)