1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-06-16 21:35:24 +00:00

Merge pull request #1730 from profanity-im/fix/scrolling

Don't scroll if not needed
This commit is contained in:
Michael Vetter 2022-06-29 15:37:07 +02:00 committed by GitHub
commit 5aa515ddfe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -598,6 +598,10 @@ win_page_up(ProfWin* window)
int page_space = rows - 4;
int* page_start = &(window->layout->y_pos);
// dont need to scroll
if (*page_start == 0)
return;
*page_start -= page_space;
// went past beginning, show first page