Add %G (halfop symbol) to the default status line.

Also change the meaning of %= in the status line so that the voice
symbol is shown whether or not the user is opped.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@50 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
Kevin Easton
2008-06-12 14:55:00 +00:00
parent 62e70f98e2
commit b5741b6ee2
2 changed files with 17 additions and 14 deletions

View File

@@ -789,7 +789,7 @@
#define DEFAULT_FORMAT_WHOLEFT_FOOTER_FSET NULL
#define DEFAULT_STATUS_FORMAT " [%T][%*%@%=%N%#%A]%M [%C%+%W] %Q %H%B%F "
#define DEFAULT_STATUS_FORMAT1 " [%T][%*%@%=%N%#%A]%M [%C%+%W] %Q %H%B%F "
#define DEFAULT_STATUS_FORMAT1 " [%T][%*%@%G%=%N%#%A]%M [%C%+%W] %Q %H%B%F "
#define DEFAULT_STATUS_FORMAT2 " %L %! %K %>%D %J[%u:%a:%f:%b:%h]"
#define DEFAULT_STATUS_FORMAT3 "BitchX by panasync "

View File

@@ -1125,19 +1125,23 @@ static char my_buffer[MY_BUFFER/2+1];
static char *status_chanop(Window *window)
{
char *text;
if (window->current_channel && get_channel_oper(window->current_channel, window->server) &&
if (window->current_channel &&
get_channel_oper(window->current_channel, window->server) &&
(text = get_wset_string_var(window->wset, STATUS_CHANOP_WSET)))
return (text);
else
return text;
RETURN_EMPTY;
}
static char *status_halfop(Window *window)
{
char *text;
if (window->current_channel && get_channel_halfop(window->current_channel, window->server) &&
if (window->current_channel &&
get_channel_halfop(window->current_channel, window->server) &&
(text = get_wset_string_var(window->wset, STATUS_HALFOP_WSET)))
return (text);
else
return text;
RETURN_EMPTY;
}
@@ -1386,7 +1390,6 @@ static char *status_voice(Window *window)
char *text;
if (window->current_channel &&
get_channel_voice(window->current_channel, window->server) &&
!get_channel_oper(window->current_channel, window->server) &&
(text = get_wset_string_var(window->wset, STATUS_VOICE_WSET)))
return text;
RETURN_EMPTY;