]> git.eshelyaron.com Git - emacs.git/commitdiff
(scrolling): If a line is not enabled,
authorRichard M. Stallman <rms@gnu.org>
Thu, 29 May 1997 03:32:17 +0000 (03:32 +0000)
committerRichard M. Stallman <rms@gnu.org>
Thu, 29 May 1997 03:32:17 +0000 (03:32 +0000)
give it an infinite draw_cost.

src/dispnew.c

index 4c0cd1b917eefccfdfa21d690b1e0007218ae2a9..ad7ed32c40a9c85132bcd2f6593a7cae742b6474 100644 (file)
@@ -1428,9 +1428,17 @@ scrolling (frame)
        return 0;
       old_hash[i] = line_hash_code (current_frame, i);
       if (! desired_frame->enable[i])
-       new_hash[i] = old_hash[i];
+       {
+         /* This line cannot be redrawn, so don't let scrolling mess it.  */
+         new_hash[i] = old_hash[i];
+#define INFINITY 1000000       /* Taken from scroll.c */
+         draw_cost[i] = INFINITY;
+       }
       else
-       new_hash[i] = line_hash_code (desired_frame, i);
+       {
+         new_hash[i] = line_hash_code (desired_frame, i);
+         draw_cost[i] = line_draw_cost (desired_frame, i);
+       }
 
       if (old_hash[i] != new_hash[i])
        {
@@ -1439,7 +1447,6 @@ scrolling (frame)
        }
       else if (i == unchanged_at_top)
        unchanged_at_top++;
-      draw_cost[i] = line_draw_cost (desired_frame, i);
       old_draw_cost[i] = line_draw_cost (current_frame, i);
     }