Commit: 0ddc8946923f4b2d439f32e7bf37152af6e7205e
Parent: f72da6db94b19d477f7939dba75f1fb7730dc251
Author: Randy Palamar
Date: Fri, 30 Aug 2024 07:54:59 -0600
correctly check if screen has swapped when splitting lines
t->mode contains different flags now so it needs to be masked.
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/terminal.c b/terminal.c
@@ -902,7 +902,7 @@ check_if_csi_moves_cursor(Term *t, s8 *raw)
if (parse_csi(raw, &csi) == -1)
return EMC_NEEDS_MORE_BYTES;
- u32 term_mode = t->mode;
+ i32 mode = t->mode & TM_ALTSCREEN;
switch (csi.mode) {
case 'A': result = EMC_CURSOR_MOVED; break;
case 'B': result = EMC_CURSOR_MOVED; break;
@@ -923,7 +923,7 @@ check_if_csi_moves_cursor(Term *t, s8 *raw)
default: break;
}
- if (term_mode != t->mode)
+ if (mode != (t->mode & TM_ALTSCREEN))
result = EMC_SWAPPED_SCREEN;
return result;