From 659e0bc92aa43838e532dadf8dbad79b25e16779 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Mon, 2 Oct 2006 20:44:44 +0000 Subject: Bug 358344 – autoscroll only works one way in fullscreen [PATCH] Patch MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 2006-10-02 Behdad Esfahbod Bug 358344 – autoscroll only works one way in fullscreen [PATCH] Patch by Egmont Koblinger * src/vte.c (vte_terminal_autoscroll), (vte_terminal_motion_notify): Fix forward autoscrolling in fullscreen mode. --- ChangeLog | 9 +++++++++ src/vte.c | 6 +++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 10f1d65..107d75e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2006-10-02 Behdad Esfahbod + + Bug 358344 – autoscroll only works one way in fullscreen [PATCH] + Patch by Egmont Koblinger + + * src/vte.c (vte_terminal_autoscroll), + (vte_terminal_motion_notify): Fix forward autoscrolling in fullscreen + mode. + 2006-09-20 Behdad Esfahbod Bug 353756 – font setting cleanup diff --git a/src/vte.c b/src/vte.c index 8c54dd9..d464e2f 100644 --- a/src/vte.c +++ b/src/vte.c @@ -5589,7 +5589,7 @@ vte_terminal_autoscroll(gpointer data) } #endif } - if (terminal->pvt->mouse_last_y > + if (terminal->pvt->mouse_last_y >= terminal->row_count * terminal->char_height) { if (terminal->adjustment) { /* Try to scroll up by one line. */ @@ -5618,7 +5618,7 @@ vte_terminal_autoscroll(gpointer data) if (terminal->pvt->mouse_last_y < 0 && !terminal->pvt->block_mode) { x = 0; } - if (terminal->pvt->mouse_last_y > ymax && !terminal->pvt->block_mode) { + if (terminal->pvt->mouse_last_y >= ymax && !terminal->pvt->block_mode) { x = terminal->column_count * terminal->char_width; } /* Extend selection to cover the newly-scrolled area. */ @@ -5727,7 +5727,7 @@ vte_terminal_motion_notify(GtkWidget *widget, GdkEventMotion *event) /* Start scrolling if we need to. */ if ((event->y < VTE_PAD_WIDTH) || - (event->y > (widget->allocation.height - VTE_PAD_WIDTH))) { + (event->y >= (terminal->row_count * terminal->char_height + VTE_PAD_WIDTH))) { switch (terminal->pvt->mouse_last_button) { case 1: if (!event_mode) { -- cgit v1.2.3