w->horizontal = horflag;
}
+static void
+wset_update_mode_line (struct window *w)
+{
+ /* If this window is the selected window on its frame, set the
+ global variable update_mode_lines, so that x_consider_frame_title
+ will consider this frame's title for rtedisplay. */
+ Lisp_Object fselected_window = XFRAME (WINDOW_FRAME (w))->selected_window;
+
+ if (WINDOWP (fselected_window) && XWINDOW (fselected_window) == w)
+ update_mode_lines = 42;
+ else
+ w->update_mode_line = true;
+}
+
/* True if leaf window W doesn't reflect the actual state
of displayed buffer due to its text or overlays change. */
w->start_at_line_beg = false;
if (NILP (noforce))
w->force_start = true;
- w->update_mode_line = true;
+ wset_update_mode_line (w);
/* Bug#15957. */
w->window_end_valid = false;
wset_redisplay (w);
/* Maybe we could move this into the `if' but it's not obviously safe and
I doubt it's worth the trouble. */
wset_redisplay (w);
- /* If this window is the selected window on its frame, set the
- global variable update_mode_lines, so that x_consider_frame_title
- will consider this frame's title for rtedisplay. */
- Lisp_Object fselected_window = XFRAME (WINDOW_FRAME (w))->selected_window;
- if (WINDOWP (fselected_window) && XWINDOW (fselected_window) == w)
- update_mode_lines = 42;
- else
- w->update_mode_line = true;
+
+ wset_update_mode_line (w);
/* We must select BUFFER to run the window-scroll-functions and to look up
the buffer-local value of Vwindow_point_insertion_type. */
set_marker_restricted (w->start, make_number (spos),
w->contents);
w->start_at_line_beg = true;
- w->update_mode_line = true;
+ wset_update_mode_line (w);
/* Set force_start so that redisplay_window will run the
window-scroll-functions. */
w->force_start = true;
IT_BYTEPOS (it));
bytepos = marker_byte_position (w->start);
w->start_at_line_beg = (pos == BEGV || FETCH_BYTE (bytepos - 1) == '\n');
- w->update_mode_line = true;
+ wset_update_mode_line (w);
/* Set force_start so that redisplay_window will run the
window-scroll-functions. */
w->force_start = true;
set_marker_restricted_both (w->start, w->contents, pos, pos_byte);
w->start_at_line_beg = !NILP (bolp);
- w->update_mode_line = true;
+ wset_update_mode_line (w);
/* Set force_start so that redisplay_window will run
the window-scroll-functions. */
w->force_start = true;