aboutsummaryrefslogtreecommitdiff
path: root/input.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2022-02-23 18:03:54 +0000
committerDaniel Eklöf <daniel@ekloef.se>2022-02-23 18:03:54 +0000
commitf869ca45467ce7d326deffcff7e270cbcc893d2c (patch)
treef8a8c1469740a57e2839a9f42140352836a95d2c /input.c
parentcommands: refactor scrollback up/down (diff)
config/input: add scrollback-home|end key bindings (unbound by default)
Diffstat (limited to 'input.c')
-rw-r--r--input.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/input.c b/input.c
index 26af0807..f402fa3d 100644
--- a/input.c
+++ b/input.c
@@ -134,6 +134,20 @@ execute_binding(struct seat *seat, struct terminal *term,
}
break;
+ case BIND_ACTION_SCROLLBACK_HOME:
+ if (term->grid == &term->normal) {
+ cmd_scrollback_up(term, term->grid->num_rows);
+ return true;
+ }
+ break;
+
+ case BIND_ACTION_SCROLLBACK_END:
+ if (term->grid == &term->normal) {
+ cmd_scrollback_down(term, term->grid->num_rows);
+ return true;
+ }
+ break;
+
case BIND_ACTION_CLIPBOARD_COPY:
selection_to_clipboard(seat, term, serial);
return true;