1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-06-29 11:56:44 +02:00

fix bug where tab alert colours weren't being properly prioritized

This commit is contained in:
Jfreegman
2014-08-07 19:53:47 -04:00
parent bb85f31bb2
commit e75cf4f3ad
3 changed files with 18 additions and 19 deletions

View File

@ -368,13 +368,12 @@ void on_window_resize(void)
}
}
static void draw_window_tab(ToxWindow toxwin)
static void draw_window_tab(ToxWindow *toxwin)
{
if (toxwin.alert) attron(COLOR_PAIR(toxwin.alert));
if (toxwin->alert != WINDOW_ALERT_NONE) attron(COLOR_PAIR(toxwin->alert));
clrtoeol();
printw(" [%s]", toxwin.name);
if (toxwin.alert) attroff(COLOR_PAIR(toxwin.alert));
printw(" [%s]", toxwin->name);
if (toxwin->alert != WINDOW_ALERT_NONE) attroff(COLOR_PAIR(toxwin->alert));
}
static void draw_bar(void)
@ -404,7 +403,7 @@ static void draw_bar(void)
attron(A_BOLD);
draw_window_tab(windows[i]);
draw_window_tab(&windows[i]);
if (windows + i == active_window)