summaryrefslogtreecommitdiffstats
path: root/input.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2007-11-16 16:28:14 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2007-11-16 16:28:14 +0000
commit86b73cec72fc178cc612a60af2ac1d0aff3c10c5 (patch)
treedca26379d88eabeaf0efc74f4e6a5fc5c38b23e3 /input.c
parentce5f02fc9eedb5848c3b9768101068f5fb92d03c (diff)
Check for scrolling when _cursor_ is inside region, not number of lines. Duh.
Diffstat (limited to 'input.c')
-rw-r--r--input.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/input.c b/input.c
index 35c8bb39..d422ae54 100644
--- a/input.c
+++ b/input.c
@@ -1,4 +1,4 @@
-/* $Id: input.c,v 1.30 2007-11-09 17:06:01 nicm Exp $ */
+/* $Id: input.c,v 1.31 2007-11-16 16:28:14 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -673,7 +673,7 @@ input_handle_sequence_dl(struct input_ctx *ictx)
return;
}
- if (n < s->ry_upper || n > s->ry_lower)
+ if (s->cy < s->ry_upper || s->cy > s->ry_lower)
screen_delete_lines(s, s->cy, n);
else
screen_delete_lines_region(s, s->cy, n);
@@ -721,7 +721,7 @@ input_handle_sequence_il(struct input_ctx *ictx)
log_debug3("il: out of range: %hu", n);
return;
}
- if (n < s->ry_upper || n > s->ry_lower)
+ if (s->cy < s->ry_upper || s->cy > s->ry_lower)
screen_insert_lines(s, s->cy, n);
else
screen_insert_lines_region(s, s->cy, n);