summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBoris Faure <billiob@gmail.com>2015-08-10 21:44:05 +0200
committerBoris Faure <billiob@gmail.com>2015-08-10 21:44:05 +0200
commitfe58cd058b8ea4de70f519e608f40aef3ea09605 (patch)
treea26bcdcd88b9765a664fd0a6092ed9eead8133bb /src
parentd0bedb9a8ab87e488559d1a51fd7fd66058356e8 (diff)
only use beacon when it seems efficient
Diffstat (limited to 'src')
-rw-r--r--src/bin/termpty.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/bin/termpty.c b/src/bin/termpty.c
index 50b86ab..66752da 100644
--- a/src/bin/termpty.c
+++ b/src/bin/termpty.c
@@ -792,6 +792,12 @@ _termpty_cellrow_from_beacon_get(Termpty *ty, int requested_y, ssize_t *wret)
792 792
793 requested_y = -requested_y; 793 requested_y = -requested_y;
794 794
795 /* check if going from 0,0 is faster than using the beacon */
796 if (screen_y - requested_y > requested_y)
797 {
798 backlog_y = 1;
799 screen_y = 1;
800 }
795 while (42) { 801 while (42) {
796 Termsave *ts; 802 Termsave *ts;
797 int nb_lines; 803 int nb_lines;