summaryrefslogtreecommitdiff
path: root/src/tabs.py
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2012-05-17 17:15:15 +0200
committermathieui <mathieui@mathieui.net>2012-05-17 17:15:15 +0200
commit3411d8ca83591adf9a92b3c1c78fbd74a4612fe7 (patch)
tree5b98602736bc9e55aabb9c238f92cfc295942bbe /src/tabs.py
parent0f8a5abdc0818b4071bf4623a12ee95223b11ba3 (diff)
downloadpoezio-3411d8ca83591adf9a92b3c1c78fbd74a4612fe7.tar.gz
poezio-3411d8ca83591adf9a92b3c1c78fbd74a4612fe7.tar.bz2
poezio-3411d8ca83591adf9a92b3c1c78fbd74a4612fe7.tar.xz
poezio-3411d8ca83591adf9a92b3c1c78fbd74a4612fe7.zip
Add a shortcut to go to the first unread message (separator) with M-p
Diffstat (limited to 'src/tabs.py')
-rw-r--r--src/tabs.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tabs.py b/src/tabs.py
index 92b913b0..61b322a0 100644
--- a/src/tabs.py
+++ b/src/tabs.py
@@ -394,6 +394,7 @@ class ChatTab(Tab):
# since the last input
self.remote_supports_attention = False
self.key_func['M-v'] = self.move_separator
+ self.key_func['M-h'] = self.scroll_separator
self.key_func['M-/'] = self.last_words_completion
self.key_func['^M'] = self.on_enter
self.commands['say'] = (self.command_say,
@@ -566,6 +567,11 @@ class ChatTab(Tab):
def on_half_scroll_down(self):
self.text_win.scroll_down((self.text_win.height-1) // 2)
+ def scroll_separator(self):
+ self.text_win.scroll_to_separator()
+ self.refresh()
+ self.core.doupdate()
+
class MucTab(ChatTab):
"""