Pre...
Content-type: text/plain
Author: andar
Revision: 5715
Log:
Fix #1009 enabling a plugin twice in the gtkui
Prevent plugins from being enabled more than once in pluginmanagerbase
Diff:
Modified: trunk/deluge/pluginmanagerbase.py
===================================================================
--- trunk/deluge/pluginmanagerbase.py 2009-09-04 16:30:56 UTC (rev 5714)
+++ trunk/deluge/pluginmanagerbase.py 2009-09-05 19:32:01 UTC (rev 5715)
@@ -122,6 +122,10 @@
log.warning("Cannot enable non-existant plugin %s", plugin_name)
return
+ if plugin_name in self.plugins:
+ log.warning("Cannot enable already enabled plugin %s", plugin_name)
+ return
+
plugin_name = plugin_name.replace(" ", "-")
egg = self.pkg_env[plugin_name][0]
egg.activate()
Modified: trunk/deluge/ui/gtkui/preferences.py
===================================================================
--- trunk/deluge/ui/gtkui/preferences.py 2009-09-04 16:30:56 UTC (rev
5714)
+++ trunk/deluge/ui/gtkui/preferences.py 2009-09-05 19:32:01 UTC (rev
5715)
@@ -882,7 +882,6 @@
self.plugin_liststore.set_value(row, 1, not value)
if not value:
client.core.enable_plugin(name)
- component.get("PluginManager").enable_plugin(name)
else:
client.core.disable_plugin(name)
component.get("PluginManager").disable_plugin(name)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"deluge-commit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/deluge-commit?hl=en
-~----------~----~----~----~------~----~------~--~---