Fix a bug in plugin unloading (commands/keys not deleted properly)
This commit is contained in:
parent
4f423f1e3a
commit
6d2af1116c
1 changed files with 3 additions and 3 deletions
|
@ -80,14 +80,14 @@ class PluginManager(object):
|
||||||
for key in self.keys[name].keys():
|
for key in self.keys[name].keys():
|
||||||
del self.core.key_func[key]
|
del self.core.key_func[key]
|
||||||
for tab in list(self.tab_commands[name].keys()):
|
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])
|
self.del_tab_command(name, getattr(tabs, tab), command[0])
|
||||||
del self.tab_commands[name][tab]
|
del self.tab_commands[name][tab]
|
||||||
for tab in list(self.tab_keys[name].keys()):
|
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])
|
self.del_tab_key(name, getattr(tabs, tab), key[0])
|
||||||
del self.tab_keys[name][tab]
|
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.del_event_handler(name, event_name, handler)
|
||||||
|
|
||||||
self.plugins[name].unload()
|
self.plugins[name].unload()
|
||||||
|
|
Loading…
Reference in a new issue