changeset 31653:2554afbeb88d

(update_window): Make sure to make desired rows current even if they are completely invisible at the top of a window.
author Gerd Moellmann <gerd@gnu.org>
date Sat, 16 Sep 2000 13:38:54 +0000
parents 41a7ba41a6ee
children 3d1b298f0f22
files src/dispnew.c
diffstat 1 files changed, 13 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/dispnew.c	Fri Sep 15 21:01:39 2000 +0000
+++ b/src/dispnew.c	Sat Sep 16 13:38:54 2000 +0000
@@ -3839,15 +3839,23 @@
 
       /* Update the rest of the lines.  */
       for (; row < end && (force_p || !input_pending); ++row)
-	if (row->enabled_p
-	    /* A row can be completely invisible in case a desired
-	       matrix was built with a vscroll and then
-	       make_cursor_line_fully_visible shifts the matrix.  */
-	    && row->visible_height > 0)
+	if (row->enabled_p)
 	  {
 	    int vpos = MATRIX_ROW_VPOS (row, desired_matrix);
 	    int i;
 	    
+	    /* A row can be completely invisible in case a desired
+	       matrix was built with a vscroll and then
+	       make_cursor_line_fully_visible shifts the matrix.
+	       Make sure to make such rows current anyway, since
+	       we need the correct y-position, for example, in the
+	       current matrix.  */
+	    if (row->visible_height <= 0)
+	      {
+		make_current (w->desired_matrix, w->current_matrix, vpos);
+		continue;
+	      }
+	    
 	    /* We'll Have to play a little bit with when to
 	       detect_input_pending.  If it's done too often,
 	       scrolling large windows with repeated scroll-up