diff options
author | mathieui <mathieui@mathieui.net> | 2018-07-22 16:17:06 +0200 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2018-07-22 16:17:06 +0200 |
commit | c6cf2d08b7295a477d89d01535463d18103f6311 (patch) | |
tree | 9ec9f61ab5d4b6fe45d10d0752dab90df935e76f /plugins/change_title.py | |
parent | e2414121af16474744d012cdb8466de6ae3136e4 (diff) | |
download | poezio-c6cf2d08b7295a477d89d01535463d18103f6311.tar.gz poezio-c6cf2d08b7295a477d89d01535463d18103f6311.tar.bz2 poezio-c6cf2d08b7295a477d89d01535463d18103f6311.tar.xz poezio-c6cf2d08b7295a477d89d01535463d18103f6311.zip |
Fix close_all and change_title plugins
Diffstat (limited to 'plugins/change_title.py')
-rw-r--r-- | plugins/change_title.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/plugins/change_title.py b/plugins/change_title.py index 92fcb5c3..e5ed96a8 100644 --- a/plugins/change_title.py +++ b/plugins/change_title.py @@ -8,7 +8,7 @@ import sys class Plugin(BasePlugin): def init(self): - self.on_tab_change(0, self.core.current_tab_nb) + self.on_tab_change(None, new_tab=self.core.tabs.current_tab) self.api.add_event_handler('tab_change', self.on_tab_change) def cleanup(self): @@ -16,8 +16,6 @@ class Plugin(BasePlugin): sys.stdout.write("\x1b]0;poezio\x07") sys.stdout.flush() - def on_tab_change(self, old, new): - new_tab = self.core.get_tab_by_number(new) + def on_tab_change(self, old_tab, new_tab): sys.stdout.write("\x1b]0;{}\x07".format(new_tab.name)) sys.stdout.flush() - |