diff options
author | Patrick Totzke <patricktotzke@gmail.com> | 2013-05-30 17:50:51 +0100 |
---|---|---|
committer | Patrick Totzke <patricktotzke@gmail.com> | 2013-05-30 17:50:51 +0100 |
commit | 75b72db88d9118e7b94df2bc54521afe5aabddbd (patch) | |
tree | 61d0d1adb8dd57ec6bbe27087db627c70dcf087f | |
parent | 62d7536185d173a2766aba8f3e2c7b1b63fbc4f7 (diff) |
make `move last` available if buffer allows it
-rw-r--r-- | alot/commands/globals.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/alot/commands/globals.py b/alot/commands/globals.py index 42718f12..01d9bdfc 100644 --- a/alot/commands/globals.py +++ b/alot/commands/globals.py @@ -836,7 +836,11 @@ class MoveCommand(Command): ui.mainloop.process_input( ui.mainloop.screen_size[1]/2 * [self.movement.split()[-1]]) elif self.movement == 'first': - ui.current_buffer.focus_first() + if hasattr(ui.current_buffer, "focus_first"): + ui.current_buffer.focus_first() + elif self.movement == 'last': + if hasattr(ui.current_buffer, "focus_last"): + ui.current_buffer.focus_last() else: ui.notify('unknown movement: ' + self.movement, priority='error') |