mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-30 01:16:21 +00:00
style(ui,window): format code and tidy comments
Whitespace and comment formatting only; no functional changes.
This commit is contained in:
@@ -701,7 +701,7 @@ void
|
|||||||
win_page_down(ProfWin* window, int scroll_size)
|
win_page_down(ProfWin* window, int scroll_size)
|
||||||
{
|
{
|
||||||
int total_rows = getcury(window->layout->win);
|
int total_rows = getcury(window->layout->win);
|
||||||
int total_rows_with_unreaded = total_rows + window->layout->unread_msg;
|
int total_rows_with_unread = total_rows + window->layout->unread_msg;
|
||||||
int* page_start = &(window->layout->y_pos);
|
int* page_start = &(window->layout->y_pos);
|
||||||
int page_space = getmaxy(stdscr) - 4;
|
int page_space = getmaxy(stdscr) - 4;
|
||||||
int page_start_initial = *page_start;
|
int page_start_initial = *page_start;
|
||||||
@@ -714,8 +714,8 @@ win_page_down(ProfWin* window, int scroll_size)
|
|||||||
*page_start += scroll_size;
|
*page_start += scroll_size;
|
||||||
|
|
||||||
// Scrolled down after reaching the bottom of the page
|
// Scrolled down after reaching the bottom of the page
|
||||||
gboolean past_bottom = *page_start > total_rows_with_unreaded - page_space;
|
gboolean past_bottom = *page_start > total_rows_with_unread - page_space;
|
||||||
gboolean at_page_space_and_past_unread = (*page_start == page_space && *page_start >= total_rows_with_unreaded);
|
gboolean at_page_space_and_past_unread = (*page_start == page_space && *page_start >= total_rows_with_unread);
|
||||||
gboolean is_chat = window->type == WIN_CHAT;
|
gboolean is_chat = window->type == WIN_CHAT;
|
||||||
|
|
||||||
if ((past_bottom || at_page_space_and_past_unread) && is_chat) {
|
if ((past_bottom || at_page_space_and_past_unread) && is_chat) {
|
||||||
|
|||||||
Reference in New Issue
Block a user