1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-07-05 03:26:46 +02:00

allow groupchat sidebar to scroll

This commit is contained in:
Jfreegman
2013-12-03 03:44:02 -05:00
parent ba750753a5
commit 1a86327f9f
3 changed files with 31 additions and 13 deletions

View File

@ -256,7 +256,7 @@ static void friendlist_onKey(ToxWindow *self, Tox *m, wint_t key)
}
}
#define FLIST_OFST 3 /* Accounts for the three lines of text at top */
#define FLIST_OFST 3 /* Accounts for the three lines at top */
static void friendlist_onDraw(ToxWindow *self, Tox *m)
{
@ -276,8 +276,7 @@ static void friendlist_onDraw(ToxWindow *self, Tox *m)
wattroff(self->window, COLOR_PAIR(CYAN) | A_BOLD);
}
if ((y2 - FLIST_OFST) == 0) /* don't allow division by zero */
if ((y2 - FLIST_OFST) <= 0) /* don't allow division by zero */
return;
/* Determine which portion of friendlist to draw based on current position */