"NONE" works now with combine_levels(). /WINDOW LEVEL NONE works and if

window doesn't have level it prints "NONE" instead of empty string.


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@674 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2000-09-26 21:44:20 +00:00 committed by cras
commit 5f752567f6
2 changed files with 7 additions and 3 deletions

View file

@ -165,8 +165,10 @@ static void cmd_window_level(const char *data)
window_set_level(active_win, combine_level(active_win->level, data));
level = bits2level(active_win->level);
printtext(NULL, NULL, MSGLEVEL_CLIENTNOTICE, "Window level is now %s", level);
level = active_win->level == 0 ? g_strdup("NONE") :
bits2level(active_win->level);
printtext(NULL, NULL, MSGLEVEL_CLIENTNOTICE,
"Window level is now %s", level);
g_free(level);
}