diff options
author | George Hazan <george.hazan@gmail.com> | 2023-08-07 19:16:46 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2023-08-07 19:16:46 +0300 |
commit | c3cb0acccd9d3585db20333ed02a7c3752b48c7a (patch) | |
tree | ce1e8d0df2ad52ae2ffa914c0e9dbad94f20db13 | |
parent | c3b92a67a6a1b1bd035e44fcdb95ad51df4387f3 (diff) |
fixes #3627 (NewStory: прокрутка мышью не позволяет вернуться к последнему сообщению)
-rw-r--r-- | plugins/NewStory/src/history_control.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/NewStory/src/history_control.cpp b/plugins/NewStory/src/history_control.cpp index 3e78830322..8830e4c148 100644 --- a/plugins/NewStory/src/history_control.cpp +++ b/plugins/NewStory/src/history_control.cpp @@ -504,7 +504,7 @@ void NewstoryListData::LineUp() void NewstoryListData::LineDown() { - if (cachedMaxDrawnItem >= totalCount) + if (cachedMaxDrawnItem >= totalCount && cachedMaxTopPixel >= 0) return; scrollTopItem++; @@ -520,7 +520,7 @@ void NewstoryListData::PageUp() if (scrollTopPixel == 0) scrollTopItem -= 10; else { - cachedMaxTopItem -= 9; + scrollTopItem -= 9; scrollTopPixel = 0; } FixScrollPosition(); @@ -529,7 +529,7 @@ void NewstoryListData::PageUp() void NewstoryListData::PageDown() { - if (cachedMaxDrawnItem >= totalCount) + if (cachedMaxDrawnItem >= totalCount && cachedMaxTopPixel >= 0) return; scrollTopItem = cachedMaxDrawnItem - 1; |