From 6d2af1116cf08feea1611e9cc27df4205e4c4fbd Mon Sep 17 00:00:00 2001 From: mathieui Date: Fri, 9 Mar 2012 23:24:29 +0100 Subject: [PATCH] Fix a bug in plugin unloading (commands/keys not deleted properly) --- src/plugin_manager.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/plugin_manager.py b/src/plugin_manager.py index 6d3fb05a..f414bb66 100644 --- a/src/plugin_manager.py +++ b/src/plugin_manager.py @@ -80,14 +80,14 @@ class PluginManager(object): for key in self.keys[name].keys(): del self.core.key_func[key] for tab in list(self.tab_commands[name].keys()): - for command in self.tab_commands[name][tab]: + for command in self.tab_commands[name][tab][:]: self.del_tab_command(name, getattr(tabs, tab), command[0]) del self.tab_commands[name][tab] for tab in list(self.tab_keys[name].keys()): - for key in self.tab_keys[name][tab]: + for key in self.tab_keys[name][tab][:]: self.del_tab_key(name, getattr(tabs, tab), key[0]) del self.tab_keys[name][tab] - for event_name, handler in self.event_handlers[name]: + for event_name, handler in self.event_handlers[name][:]: self.del_event_handler(name, event_name, handler) self.plugins[name].unload()