mirror of
https://github.com/weechat/weechat.git
synced 2026-06-12 14:14:48 +02:00
core: reset scroll after /window {page_down|scroll_down} if last line of buffer is displayed at bottom
A regression was introduced by commit bee56c3b7f
(/window scroll_beyond_end).
Scenario to reproduce the problem, for example on an IRC channel with a long
history (more than two pages):
/window page_up
/window page_down
<type some text and send to channel>
It will display -MORE(1)- instead of automatically scrolling to bottom of
buffer.
This commit is contained in:
@@ -1303,7 +1303,7 @@ gui_window_page_down (struct t_gui_window *window)
|
||||
ptr_line = window->scroll->start_line;
|
||||
line_pos = window->scroll->start_line_pos;
|
||||
gui_chat_calculate_line_diff (window, &ptr_line, &line_pos,
|
||||
window->win_chat_height - 1);
|
||||
window->win_chat_height);
|
||||
if (!ptr_line)
|
||||
{
|
||||
window->scroll->start_line = NULL;
|
||||
@@ -1392,7 +1392,7 @@ gui_window_scroll_down (struct t_gui_window *window)
|
||||
ptr_line = window->scroll->start_line;
|
||||
line_pos = window->scroll->start_line_pos;
|
||||
gui_chat_calculate_line_diff (window, &ptr_line, &line_pos,
|
||||
window->win_chat_height - 1);
|
||||
window->win_chat_height);
|
||||
|
||||
if (!ptr_line)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user