summaryrefslogtreecommitdiffstats
path: root/input.c
diff options
context:
space:
mode:
authornicm <nicm>2017-10-05 13:29:18 +0000
committernicm <nicm>2017-10-05 13:29:18 +0000
commit88517ceebb6cf31f661a1e265b2db6cbf61f09eb (patch)
tree85400ddd4b916ab9d413f18009f681d3abf9cd4e /input.c
parent6a292f09ba575690c8af3ff8b5a94acbbe6acacf (diff)
Add support for the xterm(1) title stack, from Brad Town, GitHub issue
1075.
Diffstat (limited to 'input.c')
-rw-r--r--input.c23
1 files changed, 22 insertions, 1 deletions
diff --git a/input.c b/input.c
index e4aecf7d..42ff7f3b 100644
--- a/input.c
+++ b/input.c
@@ -1693,11 +1693,32 @@ input_csi_dispatch_winops(struct input_ctx *ictx)
/* FALLTHROUGH */
case 9:
case 10:
+ m++;
+ if (input_get(ictx, m, 0, -1) == -1)
+ return;
+ break;
case 22:
+ m++;
+ switch (input_get(ictx, m, 0, -1)) {
+ case -1:
+ return;
+ case 0:
+ case 2:
+ screen_push_title(ictx->ctx.s);
+ break;
+ }
+ break;
case 23:
m++;
- if (input_get(ictx, m, 0, -1) == -1)
+ switch (input_get(ictx, m, 0, -1)) {
+ case -1:
return;
+ case 0:
+ case 2:
+ screen_pop_title(ictx->ctx.s);
+ server_status_window(ictx->wp->window);
+ break;
+ }
break;
case 18:
input_reply(ictx, "\033[8;%u;%ut", wp->sy, wp->sx);