diff options
| author | Richard M. Stallman | 1998-10-12 01:38:50 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1998-10-12 01:38:50 +0000 |
| commit | b5174a51038a782ff1d80f303252f04b72dbdc03 (patch) | |
| tree | b69a434df1897701a8517c3a8fa9ea4cfef113bb /src | |
| parent | 4fba3b2c067e2665e38b9557eb230cefcbb33235 (diff) | |
| download | emacs-b5174a51038a782ff1d80f303252f04b72dbdc03.tar.gz emacs-b5174a51038a782ff1d80f303252f04b72dbdc03.zip | |
(redisplay_window): Clear w->window_end_valid
before running the window-scroll-functions hook, if appropriate.
Diffstat (limited to 'src')
| -rw-r--r-- | src/xdisp.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index 9abc887a747..f2551fc1cbd 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -1951,6 +1951,8 @@ redisplay_window (window, just_this_one, preserve_echo_area) | |||
| 1951 | w->force_start = Qnil; | 1951 | w->force_start = Qnil; |
| 1952 | /* Forget any recorded base line for line number display. */ | 1952 | /* Forget any recorded base line for line number display. */ |
| 1953 | w->base_line_number = Qnil; | 1953 | w->base_line_number = Qnil; |
| 1954 | /* The old bottom-of-screen position is no longer valid. */ | ||
| 1955 | w->window_end_valid = Qnil; | ||
| 1954 | /* Redisplay the mode line. Select the buffer properly for that. | 1956 | /* Redisplay the mode line. Select the buffer properly for that. |
| 1955 | Also, run the hook window-scroll-functions | 1957 | Also, run the hook window-scroll-functions |
| 1956 | because we have scrolled. */ | 1958 | because we have scrolled. */ |
| @@ -2275,6 +2277,8 @@ redisplay_window (window, just_this_one, preserve_echo_area) | |||
| 2275 | scroll_conservatively ? pos.vpos + 1 : scroll_step, | 2277 | scroll_conservatively ? pos.vpos + 1 : scroll_step, |
| 2276 | w); | 2278 | w); |
| 2277 | 2279 | ||
| 2280 | /* The old bottom-of-screen position is no longer valid. */ | ||
| 2281 | w->window_end_valid = Qnil; | ||
| 2278 | if (! NILP (Vwindow_scroll_functions)) | 2282 | if (! NILP (Vwindow_scroll_functions)) |
| 2279 | { | 2283 | { |
| 2280 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); | 2284 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); |
| @@ -2316,6 +2320,8 @@ redisplay_window (window, just_this_one, preserve_echo_area) | |||
| 2316 | scroll_conservatively ? -pos.vpos : - scroll_step, | 2320 | scroll_conservatively ? -pos.vpos : - scroll_step, |
| 2317 | w); | 2321 | w); |
| 2318 | 2322 | ||
| 2323 | /* The old bottom-of-screen position is no longer valid. */ | ||
| 2324 | w->window_end_valid = Qnil; | ||
| 2319 | if (! NILP (Vwindow_scroll_functions)) | 2325 | if (! NILP (Vwindow_scroll_functions)) |
| 2320 | { | 2326 | { |
| 2321 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); | 2327 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); |
| @@ -2356,6 +2362,9 @@ redisplay_window (window, just_this_one, preserve_echo_area) | |||
| 2356 | 2362 | ||
| 2357 | if (PT >= pos.bufpos) | 2363 | if (PT >= pos.bufpos) |
| 2358 | { | 2364 | { |
| 2365 | /* The old bottom-of-screen position is no longer valid. */ | ||
| 2366 | w->window_end_valid = Qnil; | ||
| 2367 | |||
| 2359 | if (! NILP (Vwindow_scroll_functions)) | 2368 | if (! NILP (Vwindow_scroll_functions)) |
| 2360 | { | 2369 | { |
| 2361 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); | 2370 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); |
| @@ -2406,6 +2415,9 @@ recenter: | |||
| 2406 | /* Set startp here explicitly in case that helps avoid an infinite loop | 2415 | /* Set startp here explicitly in case that helps avoid an infinite loop |
| 2407 | in case the window-scroll-functions functions get errors. */ | 2416 | in case the window-scroll-functions functions get errors. */ |
| 2408 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); | 2417 | set_marker_both (w->start, Qnil, pos.bufpos, pos.bytepos); |
| 2418 | |||
| 2419 | /* The old bottom-of-screen position is no longer valid. */ | ||
| 2420 | w->window_end_valid = Qnil; | ||
| 2409 | if (! NILP (Vwindow_scroll_functions)) | 2421 | if (! NILP (Vwindow_scroll_functions)) |
| 2410 | { | 2422 | { |
| 2411 | run_hook_with_args_2 (Qwindow_scroll_functions, window, | 2423 | run_hook_with_args_2 (Qwindow_scroll_functions, window, |