aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorStefan Monnier2013-11-06 13:41:31 -0500
committerStefan Monnier2013-11-06 13:41:31 -0500
commit2ec9db5d1e97275a2a4c27e04ed6f3e8c3382cab (patch)
treec84a7a326b41b7e74e084cee68cb1fcfcf7b9131 /src
parent6b4ac03ebef0dcd36699c34444ddce7a246c06aa (diff)
downloademacs-2ec9db5d1e97275a2a4c27e04ed6f3e8c3382cab.tar.gz
emacs-2ec9db5d1e97275a2a4c27e04ed6f3e8c3382cab.zip
* src/xdisp.c (syms_of_xdisp): New vars redisplay--all-windows-cause and
redisplay--mode-lines-cause. (redisplay_internal): Keep them uptodate. Remove redundant check of buffer_shared_and_changed. * *.[chm]: Number every assignment to update_mode_lines so we can track why it is set.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog9
-rw-r--r--src/buffer.c6
-rw-r--r--src/commands.h4
-rw-r--r--src/dosfns.c2
-rw-r--r--src/fileio.c2
-rw-r--r--src/frame.c4
-rw-r--r--src/keyboard.c4
-rw-r--r--src/macros.c6
-rw-r--r--src/nsfns.m12
-rw-r--r--src/process.c4
-rw-r--r--src/w32fns.c4
-rw-r--r--src/window.c6
-rw-r--r--src/xdisp.c68
-rw-r--r--src/xfns.c4
14 files changed, 87 insertions, 48 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 19186ea3bbf..07e27ac820c 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,12 @@
12013-11-06 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * xdisp.c (syms_of_xdisp): New vars redisplay--all-windows-cause and
4 redisplay--mode-lines-cause.
5 (redisplay_internal): Keep them uptodate. Remove redundant check of
6 buffer_shared_and_changed.
7 * *.[chm]: Number every assignment to update_mode_lines so we
8 can track why it is set.
9
12013-11-06 Eli Zaretskii <eliz@gnu.org> 102013-11-06 Eli Zaretskii <eliz@gnu.org>
2 11
3 * editfns.c (Fformat_time_string): Doc fix. (Bug#15816) 12 * editfns.c (Fformat_time_string): Doc fix. (Bug#15816)
diff --git a/src/buffer.c b/src/buffer.c
index 9aed1909bbd..d3288ad0429 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -1393,7 +1393,7 @@ A non-nil FLAG means mark the buffer modified. */)
1393 smarter about updating the `*' in mode lines. --gerd */ 1393 smarter about updating the `*' in mode lines. --gerd */
1394 if (buffer_window_count (current_buffer)) 1394 if (buffer_window_count (current_buffer))
1395 { 1395 {
1396 ++update_mode_lines; 1396 update_mode_lines = 10;
1397 current_buffer->prevent_redisplay_optimizations_p = 1; 1397 current_buffer->prevent_redisplay_optimizations_p = 1;
1398 } 1398 }
1399 1399
@@ -1513,7 +1513,7 @@ This does not change the name of the visited file (if any). */)
1513 1513
1514 /* Catch redisplay's attention. Unless we do this, the mode lines for 1514 /* Catch redisplay's attention. Unless we do this, the mode lines for
1515 any windows displaying current_buffer will stay unchanged. */ 1515 any windows displaying current_buffer will stay unchanged. */
1516 update_mode_lines++; 1516 update_mode_lines = 11;
1517 1517
1518 XSETBUFFER (buf, current_buffer); 1518 XSETBUFFER (buf, current_buffer);
1519 Fsetcar (Frassq (buf, Vbuffer_alist), newname); 1519 Fsetcar (Frassq (buf, Vbuffer_alist), newname);
@@ -2765,7 +2765,7 @@ the normal hook `change-major-mode-hook'. */)
2765 2765
2766 /* Force mode-line redisplay. Useful here because all major mode 2766 /* Force mode-line redisplay. Useful here because all major mode
2767 commands call this function. */ 2767 commands call this function. */
2768 update_mode_lines++; 2768 update_mode_lines = 12;
2769 2769
2770 return Qnil; 2770 return Qnil;
2771} 2771}
diff --git a/src/commands.h b/src/commands.h
index 35c2c05fe72..b7f0049515d 100644
--- a/src/commands.h
+++ b/src/commands.h
@@ -36,10 +36,10 @@ extern Lisp_Object control_x_map;
36 events until a non-ASCII event is acceptable as input. */ 36 events until a non-ASCII event is acceptable as input. */
37extern Lisp_Object unread_switch_frame; 37extern Lisp_Object unread_switch_frame;
38 38
39/* Nonzero if input is coming from the keyboard */ 39/* Nonzero if input is coming from the keyboard. */
40 40
41#define INTERACTIVE (NILP (Vexecuting_kbd_macro) && !noninteractive) 41#define INTERACTIVE (NILP (Vexecuting_kbd_macro) && !noninteractive)
42 42
43/* Set this nonzero to force reconsideration of mode line. */ 43/* Set this nonzero to force reconsideration of mode line. */
44 44
45extern int update_mode_lines; 45extern int update_mode_lines;
diff --git a/src/dosfns.c b/src/dosfns.c
index 37d3998b5ee..426da1fb41a 100644
--- a/src/dosfns.c
+++ b/src/dosfns.c
@@ -472,7 +472,7 @@ x_set_title (struct frame *f, Lisp_Object name)
472 if (EQ (name, f->title)) 472 if (EQ (name, f->title))
473 return; 473 return;
474 474
475 update_mode_lines = 1; 475 update_mode_lines = 13;
476 476
477 fset_title (f, name); 477 fset_title (f, name);
478 478
diff --git a/src/fileio.c b/src/fileio.c
index d54c43c4635..d42b3811d76 100644
--- a/src/fileio.c
+++ b/src/fileio.c
@@ -4997,7 +4997,7 @@ write_region (Lisp_Object start, Lisp_Object end, Lisp_Object filename,
4997 SAVE_MODIFF = MODIFF; 4997 SAVE_MODIFF = MODIFF;
4998 XSETFASTINT (BVAR (current_buffer, save_length), Z - BEG); 4998 XSETFASTINT (BVAR (current_buffer, save_length), Z - BEG);
4999 bset_filename (current_buffer, visit_file); 4999 bset_filename (current_buffer, visit_file);
5000 update_mode_lines++; 5000 update_mode_lines = 14;
5001 } 5001 }
5002 else if (quietly) 5002 else if (quietly)
5003 { 5003 {
diff --git a/src/frame.c b/src/frame.c
index 05f74e4b621..4494edda5d7 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -1489,7 +1489,7 @@ delete_frame (Lisp_Object frame, Lisp_Object force)
1489 1489
1490 /* Cause frame titles to update--necessary if we now have just one frame. */ 1490 /* Cause frame titles to update--necessary if we now have just one frame. */
1491 if (!is_tooltip_frame) 1491 if (!is_tooltip_frame)
1492 update_mode_lines = 1; 1492 update_mode_lines = 15;
1493 1493
1494 return Qnil; 1494 return Qnil;
1495} 1495}
@@ -2025,7 +2025,7 @@ set_term_frame_name (struct frame *f, Lisp_Object name)
2025 } 2025 }
2026 2026
2027 fset_name (f, name); 2027 fset_name (f, name);
2028 update_mode_lines = 1; 2028 update_mode_lines = 16;
2029} 2029}
2030 2030
2031void 2031void
diff --git a/src/keyboard.c b/src/keyboard.c
index 81713dc5115..1231b4ca30d 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -821,7 +821,7 @@ This function is called by the editor initialization to begin editing. */)
821 return Qnil; 821 return Qnil;
822 822
823 command_loop_level++; 823 command_loop_level++;
824 update_mode_lines = 1; 824 update_mode_lines = 17;
825 825
826 if (command_loop_level 826 if (command_loop_level
827 && current_buffer != XBUFFER (XWINDOW (selected_window)->contents)) 827 && current_buffer != XBUFFER (XWINDOW (selected_window)->contents))
@@ -848,7 +848,7 @@ recursive_edit_unwind (Lisp_Object buffer)
848 Fset_buffer (buffer); 848 Fset_buffer (buffer);
849 849
850 command_loop_level--; 850 command_loop_level--;
851 update_mode_lines = 1; 851 update_mode_lines = 18;
852} 852}
853 853
854 854
diff --git a/src/macros.c b/src/macros.c
index 0c11efcdc9a..232188a408b 100644
--- a/src/macros.c
+++ b/src/macros.c
@@ -55,7 +55,7 @@ Use \\[name-last-kbd-macro] to give it a permanent name.
55Non-nil arg (prefix arg) means append to last macro defined; 55Non-nil arg (prefix arg) means append to last macro defined;
56this begins by re-executing that macro as if you typed it again. 56this begins by re-executing that macro as if you typed it again.
57If optional second arg, NO-EXEC, is non-nil, do not re-execute last 57If optional second arg, NO-EXEC, is non-nil, do not re-execute last
58macro before appending to it. */) 58macro before appending to it. */)
59 (Lisp_Object append, Lisp_Object no_exec) 59 (Lisp_Object append, Lisp_Object no_exec)
60{ 60{
61 if (!NILP (KVAR (current_kboard, defining_kbd_macro))) 61 if (!NILP (KVAR (current_kboard, defining_kbd_macro)))
@@ -66,7 +66,7 @@ macro before appending to it. */)
66 current_kboard->kbd_macro_buffer = xmalloc (30 * word_size); 66 current_kboard->kbd_macro_buffer = xmalloc (30 * word_size);
67 current_kboard->kbd_macro_bufsize = 30; 67 current_kboard->kbd_macro_bufsize = 30;
68 } 68 }
69 update_mode_lines++; 69 update_mode_lines = 19;
70 if (NILP (append)) 70 if (NILP (append))
71 { 71 {
72 if (current_kboard->kbd_macro_bufsize > 200) 72 if (current_kboard->kbd_macro_bufsize > 200)
@@ -138,7 +138,7 @@ void
138end_kbd_macro (void) 138end_kbd_macro (void)
139{ 139{
140 kset_defining_kbd_macro (current_kboard, Qnil); 140 kset_defining_kbd_macro (current_kboard, Qnil);
141 update_mode_lines++; 141 update_mode_lines = 20;
142 kset_last_kbd_macro 142 kset_last_kbd_macro
143 (current_kboard, 143 (current_kboard,
144 make_event_array ((current_kboard->kbd_macro_end 144 make_event_array ((current_kboard->kbd_macro_end
diff --git a/src/nsfns.m b/src/nsfns.m
index 7dea868e341..ee6020f2b43 100644
--- a/src/nsfns.m
+++ b/src/nsfns.m
@@ -451,8 +451,8 @@ ns_set_name_internal (struct frame *f, Lisp_Object name)
451 451
452 str = [NSString stringWithUTF8String: SSDATA (encoded_icon_name)]; 452 str = [NSString stringWithUTF8String: SSDATA (encoded_icon_name)];
453 453
454 if ([[view window] miniwindowTitle] && 454 if ([[view window] miniwindowTitle]
455 ! [[[view window] miniwindowTitle] isEqualToString: str]) 455 && ! [[[view window] miniwindowTitle] isEqualToString: str])
456 [[view window] setMiniwindowTitle: str]; 456 [[view window] setMiniwindowTitle: str];
457 457
458} 458}
@@ -469,7 +469,7 @@ ns_set_name (struct frame *f, Lisp_Object name, int explicit)
469 /* If we're switching from explicit to implicit, we had better 469 /* If we're switching from explicit to implicit, we had better
470 update the mode lines and thereby update the title. */ 470 update the mode lines and thereby update the title. */
471 if (f->explicit_name && NILP (name)) 471 if (f->explicit_name && NILP (name))
472 update_mode_lines = 1; 472 update_mode_lines = 21;
473 473
474 f->explicit_name = ! NILP (name); 474 f->explicit_name = ! NILP (name);
475 } 475 }
@@ -477,7 +477,7 @@ ns_set_name (struct frame *f, Lisp_Object name, int explicit)
477 return; 477 return;
478 478
479 if (NILP (name)) 479 if (NILP (name))
480 name = build_string([ns_app_name UTF8String]); 480 name = build_string ([ns_app_name UTF8String]);
481 else 481 else
482 CHECK_STRING (name); 482 CHECK_STRING (name);
483 483
@@ -487,7 +487,7 @@ ns_set_name (struct frame *f, Lisp_Object name, int explicit)
487 487
488 fset_name (f, name); 488 fset_name (f, name);
489 489
490 /* title overrides explicit name */ 490 /* Title overrides explicit name. */
491 if (! NILP (f->title)) 491 if (! NILP (f->title))
492 name = f->title; 492 name = f->title;
493 493
@@ -534,7 +534,7 @@ x_set_title (struct frame *f, Lisp_Object name, Lisp_Object old_name)
534 if (EQ (name, f->title)) 534 if (EQ (name, f->title))
535 return; 535 return;
536 536
537 update_mode_lines = 1; 537 update_mode_lines = 22;
538 538
539 fset_title (f, name); 539 fset_title (f, name);
540 540
diff --git a/src/process.c b/src/process.c
index c0c522a1403..307eab3ab30 100644
--- a/src/process.c
+++ b/src/process.c
@@ -5246,7 +5246,7 @@ DEFUN ("internal-default-process-filter", Finternal_default_process_filter,
5246 else 5246 else
5247 set_marker_both (p->mark, p->buffer, PT, PT_BYTE); 5247 set_marker_both (p->mark, p->buffer, PT, PT_BYTE);
5248 5248
5249 update_mode_lines++; 5249 update_mode_lines = 23;
5250 5250
5251 /* Make sure opoint and the old restrictions 5251 /* Make sure opoint and the old restrictions
5252 float ahead of any new text just as point would. */ 5252 float ahead of any new text just as point would. */
@@ -6390,7 +6390,7 @@ status_notify (struct Lisp_Process *deleting_process)
6390 } 6390 }
6391 } /* end for */ 6391 } /* end for */
6392 6392
6393 update_mode_lines++; /* In case buffers use %s in mode-line-format. */ 6393 update_mode_lines = 24; /* In case buffers use %s in mode-line-format. */
6394 UNGCPRO; 6394 UNGCPRO;
6395} 6395}
6396 6396
diff --git a/src/w32fns.c b/src/w32fns.c
index 84a504e84c2..403a7ba0d6a 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -1740,7 +1740,7 @@ x_set_name (struct frame *f, Lisp_Object name, int explicit)
1740 /* If we're switching from explicit to implicit, we had better 1740 /* If we're switching from explicit to implicit, we had better
1741 update the mode lines and thereby update the title. */ 1741 update the mode lines and thereby update the title. */
1742 if (f->explicit_name && NILP (name)) 1742 if (f->explicit_name && NILP (name))
1743 update_mode_lines = 1; 1743 update_mode_lines = 25;
1744 1744
1745 f->explicit_name = ! NILP (name); 1745 f->explicit_name = ! NILP (name);
1746 } 1746 }
@@ -1808,7 +1808,7 @@ x_set_title (struct frame *f, Lisp_Object name, Lisp_Object old_name)
1808 if (EQ (name, f->title)) 1808 if (EQ (name, f->title))
1809 return; 1809 return;
1810 1810
1811 update_mode_lines = 1; 1811 update_mode_lines = 26;
1812 1812
1813 fset_title (f, name); 1813 fset_title (f, name);
1814 1814
diff --git a/src/window.c b/src/window.c
index ac6bac42800..bc0adaf459f 100644
--- a/src/window.c
+++ b/src/window.c
@@ -2639,7 +2639,7 @@ window_loop (enum window_loop type, Lisp_Object obj, int mini, Lisp_Object frame
2639 mark_window_display_accurate (window, 0); 2639 mark_window_display_accurate (window, 0);
2640 w->update_mode_line = 1; 2640 w->update_mode_line = 1;
2641 XBUFFER (obj)->prevent_redisplay_optimizations_p = 1; 2641 XBUFFER (obj)->prevent_redisplay_optimizations_p = 1;
2642 ++update_mode_lines; 2642 update_mode_lines = 27;
2643 best_window = window; 2643 best_window = window;
2644 } 2644 }
2645 break; 2645 break;
@@ -3279,7 +3279,7 @@ displaying that buffer. */)
3279 if (NILP (object)) 3279 if (NILP (object))
3280 { 3280 {
3281 windows_or_buffers_changed = 29; 3281 windows_or_buffers_changed = 29;
3282 update_mode_lines++; 3282 update_mode_lines = 28;
3283 return Qt; 3283 return Qt;
3284 } 3284 }
3285 3285
@@ -3290,7 +3290,7 @@ displaying that buffer. */)
3290 w->update_mode_line = 1; 3290 w->update_mode_line = 1;
3291 if (BUFFERP (w->contents)) 3291 if (BUFFERP (w->contents))
3292 XBUFFER (w->contents)->prevent_redisplay_optimizations_p = 1; 3292 XBUFFER (w->contents)->prevent_redisplay_optimizations_p = 1;
3293 ++update_mode_lines; 3293 update_mode_lines = 29;
3294 return Qt; 3294 return Qt;
3295 } 3295 }
3296 3296
diff --git a/src/xdisp.c b/src/xdisp.c
index 0ec1bd2cea9..b1251aad511 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -10337,7 +10337,7 @@ resize_echo_area_exactly (void)
10337 if (resized_p) 10337 if (resized_p)
10338 { 10338 {
10339 windows_or_buffers_changed = 42; 10339 windows_or_buffers_changed = 42;
10340 ++update_mode_lines; 10340 update_mode_lines = 30;
10341 redisplay_internal (); 10341 redisplay_internal ();
10342 } 10342 }
10343 } 10343 }
@@ -12886,12 +12886,12 @@ redisplay_internal (void)
12886 int polling_stopped_here = 0; 12886 int polling_stopped_here = 0;
12887 Lisp_Object tail, frame; 12887 Lisp_Object tail, frame;
12888 12888
12889 /* Non-zero means redisplay has to consider all windows on all 12889 /* True means redisplay has to consider all windows on all
12890 frames. Zero means, only selected_window is considered. */ 12890 frames. False, only selected_window is considered. */
12891 int consider_all_windows_p; 12891 bool consider_all_windows_p;
12892 12892
12893 /* Non-zero means redisplay has to redisplay the miniwindow. */ 12893 /* True means redisplay has to redisplay the miniwindow. */
12894 int update_miniwindow_p = 0; 12894 bool update_miniwindow_p = false;
12895 12895
12896 TRACE ((stderr, "redisplay_internal %d\n", redisplaying_p)); 12896 TRACE ((stderr, "redisplay_internal %d\n", redisplaying_p));
12897 12897
@@ -12984,7 +12984,7 @@ redisplay_internal (void)
12984 /* If cursor type has been changed on the frame 12984 /* If cursor type has been changed on the frame
12985 other than selected, consider all frames. */ 12985 other than selected, consider all frames. */
12986 if (f != sf && f->cursor_type_changed) 12986 if (f != sf && f->cursor_type_changed)
12987 update_mode_lines++; 12987 update_mode_lines = 31;
12988 } 12988 }
12989 clear_desired_matrices (f); 12989 clear_desired_matrices (f);
12990 } 12990 }
@@ -13004,8 +13004,8 @@ redisplay_internal (void)
13004 if (NILP (Vmemory_full)) 13004 if (NILP (Vmemory_full))
13005 prepare_menu_bars (); 13005 prepare_menu_bars ();
13006 13006
13007 if (windows_or_buffers_changed) 13007 if (windows_or_buffers_changed & !update_mode_lines)
13008 update_mode_lines++; 13008 update_mode_lines = 32;
13009 13009
13010 reconsider_clip_changes (w); 13010 reconsider_clip_changes (w);
13011 13011
@@ -13018,7 +13018,7 @@ redisplay_internal (void)
13018 { 13018 {
13019 w->update_mode_line = 1; 13019 w->update_mode_line = 1;
13020 if (buffer_shared_and_changed ()) 13020 if (buffer_shared_and_changed ())
13021 update_mode_lines++; 13021 update_mode_lines = 33;
13022 } 13022 }
13023 13023
13024 if (mode_line_update_needed (w)) 13024 if (mode_line_update_needed (w))
@@ -13031,7 +13031,10 @@ redisplay_internal (void)
13031 /* If specs for an arrow have changed, do thorough redisplay 13031 /* If specs for an arrow have changed, do thorough redisplay
13032 to ensure we remove any arrow that should no longer exist. */ 13032 to ensure we remove any arrow that should no longer exist. */
13033 if (overlay_arrows_changed_p ()) 13033 if (overlay_arrows_changed_p ())
13034 consider_all_windows_p = windows_or_buffers_changed = 49; 13034 {
13035 consider_all_windows_p = true;
13036 windows_or_buffers_changed = 49;
13037 }
13035 13038
13036 /* Normally the message* functions will have already displayed and 13039 /* Normally the message* functions will have already displayed and
13037 updated the echo area, but the frame may have been trashed, or 13040 updated the echo area, but the frame may have been trashed, or
@@ -13049,7 +13052,7 @@ redisplay_internal (void)
13049 int window_height_changed_p = echo_area_display (0); 13052 int window_height_changed_p = echo_area_display (0);
13050 13053
13051 if (message_cleared_p) 13054 if (message_cleared_p)
13052 update_miniwindow_p = 1; 13055 update_miniwindow_p = true;
13053 13056
13054 must_finish = 1; 13057 must_finish = 1;
13055 13058
@@ -13062,8 +13065,8 @@ redisplay_internal (void)
13062 13065
13063 if (window_height_changed_p) 13066 if (window_height_changed_p)
13064 { 13067 {
13065 consider_all_windows_p = 1; 13068 consider_all_windows_p = true;
13066 ++update_mode_lines; 13069 update_mode_lines = 34;
13067 windows_or_buffers_changed = 50; 13070 windows_or_buffers_changed = 50;
13068 13071
13069 /* If window configuration was changed, frames may have been 13072 /* If window configuration was changed, frames may have been
@@ -13083,9 +13086,9 @@ redisplay_internal (void)
13083 since only the current frame needs to be considered. This function 13086 since only the current frame needs to be considered. This function
13084 needs to be rewritten with two variables, consider_all_windows and 13087 needs to be rewritten with two variables, consider_all_windows and
13085 consider_all_frames. */ 13088 consider_all_frames. */
13086 consider_all_windows_p = 1; 13089 consider_all_windows_p = true;
13087 windows_or_buffers_changed = 51; 13090 windows_or_buffers_changed = 51;
13088 ++update_mode_lines; 13091 update_mode_lines = 35;
13089 13092
13090 /* If window configuration was changed, frames may have been 13093 /* If window configuration was changed, frames may have been
13091 marked garbaged. Clear them or we will experience 13094 marked garbaged. Clear them or we will experience
@@ -13093,6 +13096,24 @@ redisplay_internal (void)
13093 clear_garbaged_frames (); 13096 clear_garbaged_frames ();
13094 } 13097 }
13095 13098
13099 if (VECTORP (Vredisplay__all_windows_cause)
13100 && windows_or_buffers_changed >= 0
13101 && windows_or_buffers_changed < ASIZE (Vredisplay__all_windows_cause)
13102 && INTEGERP (AREF (Vredisplay__all_windows_cause,
13103 windows_or_buffers_changed)))
13104 ASET (Vredisplay__all_windows_cause, windows_or_buffers_changed,
13105 make_number (1 + XINT (AREF (Vredisplay__all_windows_cause,
13106 windows_or_buffers_changed))));
13107
13108 if (VECTORP (Vredisplay__mode_lines_cause)
13109 && update_mode_lines >= 0
13110 && update_mode_lines < ASIZE (Vredisplay__mode_lines_cause)
13111 && INTEGERP (AREF (Vredisplay__mode_lines_cause,
13112 update_mode_lines)))
13113 ASET (Vredisplay__mode_lines_cause, update_mode_lines,
13114 make_number (1 + XINT (AREF (Vredisplay__mode_lines_cause,
13115 update_mode_lines))));
13116
13096 /* Optimize the case that only the line containing the cursor in the 13117 /* Optimize the case that only the line containing the cursor in the
13097 selected window has changed. Variables starting with this_ are 13118 selected window has changed. Variables starting with this_ are
13098 set in display_line and record information about the line 13119 set in display_line and record information about the line
@@ -13294,7 +13315,6 @@ redisplay_internal (void)
13294 } 13315 }
13295 13316
13296 CHARPOS (this_line_start_pos) = 0; 13317 CHARPOS (this_line_start_pos) = 0;
13297 consider_all_windows_p |= buffer_shared_and_changed ();
13298 ++clear_face_cache_count; 13318 ++clear_face_cache_count;
13299#ifdef HAVE_WINDOW_SYSTEM 13319#ifdef HAVE_WINDOW_SYSTEM
13300 ++clear_image_cache_count; 13320 ++clear_image_cache_count;
@@ -13473,7 +13493,7 @@ redisplay_internal (void)
13473 matrices of some windows are not valid. */ 13493 matrices of some windows are not valid. */
13474 if (!WINDOW_FULL_WIDTH_P (w) 13494 if (!WINDOW_FULL_WIDTH_P (w)
13475 && !FRAME_WINDOW_P (XFRAME (w->frame))) 13495 && !FRAME_WINDOW_P (XFRAME (w->frame)))
13476 update_mode_lines = 1; 13496 update_mode_lines = 36;
13477 } 13497 }
13478 else 13498 else
13479 { 13499 {
@@ -15337,7 +15357,7 @@ redisplay_window (Lisp_Object window, int just_this_one_p)
15337 } 15357 }
15338 else if ((w != XWINDOW (minibuf_window) 15358 else if ((w != XWINDOW (minibuf_window)
15339 || minibuf_level == 0) 15359 || minibuf_level == 0)
15340 /* When buffer is nonempty, redisplay window normally. */ 15360 /* When buffer is nonempty, redisplay window normally. */
15341 && BUF_Z (XBUFFER (w->contents)) == BUF_BEG (XBUFFER (w->contents)) 15361 && BUF_Z (XBUFFER (w->contents)) == BUF_BEG (XBUFFER (w->contents))
15342 /* Quail displays non-mini buffers in minibuffer window. 15362 /* Quail displays non-mini buffers in minibuffer window.
15343 In that case, redisplay the window normally. */ 15363 In that case, redisplay the window normally. */
@@ -29735,6 +29755,16 @@ display table takes effect; in this case, Emacs does not consult
29735 DEFVAR_LISP ("debug-on-message", Vdebug_on_message, 29755 DEFVAR_LISP ("debug-on-message", Vdebug_on_message,
29736 doc: /* If non-nil, debug if a message matching this regexp is displayed. */); 29756 doc: /* If non-nil, debug if a message matching this regexp is displayed. */);
29737 Vdebug_on_message = Qnil; 29757 Vdebug_on_message = Qnil;
29758
29759 DEFVAR_LISP ("redisplay--all-windows-cause", Vredisplay__all_windows_cause,
29760 doc: /* */);
29761 Vredisplay__all_windows_cause
29762 = Fmake_vector (make_number (100), make_number (0));
29763
29764 DEFVAR_LISP ("redisplay--mode-lines-cause", Vredisplay__mode_lines_cause,
29765 doc: /* */);
29766 Vredisplay__mode_lines_cause
29767 = Fmake_vector (make_number (100), make_number (0));
29738} 29768}
29739 29769
29740 29770
diff --git a/src/xfns.c b/src/xfns.c
index 624c16fe0fb..42e7c2eeec5 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -1383,7 +1383,7 @@ x_set_name (struct frame *f, Lisp_Object name, int explicit)
1383 /* If we're switching from explicit to implicit, we had better 1383 /* If we're switching from explicit to implicit, we had better
1384 update the mode lines and thereby update the title. */ 1384 update the mode lines and thereby update the title. */
1385 if (f->explicit_name && NILP (name)) 1385 if (f->explicit_name && NILP (name))
1386 update_mode_lines = 1; 1386 update_mode_lines = 37;
1387 1387
1388 f->explicit_name = ! NILP (name); 1388 f->explicit_name = ! NILP (name);
1389 } 1389 }
@@ -1445,7 +1445,7 @@ x_set_title (struct frame *f, Lisp_Object name, Lisp_Object old_name)
1445 if (EQ (name, f->title)) 1445 if (EQ (name, f->title))
1446 return; 1446 return;
1447 1447
1448 update_mode_lines = 1; 1448 update_mode_lines = 38;
1449 1449
1450 fset_title (f, name); 1450 fset_title (f, name);
1451 1451