From 6b892b39592bc3fdf7e94616917f39ec071d390d Mon Sep 17 00:00:00 2001 From: Tim Angus Date: Sun, 3 Dec 2006 23:01:59 +0000 Subject: * Strip leading whitespace when displaying server names in the browser * Sort by server name on alpha characters only * Refresh master server IP address cache on map change --- src/ui/ui_main.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'src/ui') diff --git a/src/ui/ui_main.c b/src/ui/ui_main.c index b323322e..aadad4fa 100644 --- a/src/ui/ui_main.c +++ b/src/ui/ui_main.c @@ -5042,10 +5042,18 @@ static const char *UI_FeederItemText(float feederID, int index, int column, qhan netnames[atoi(Info_ValueForKey(info, "nettype"))] ); return hostname; } - else { + else + { + char *text; + Com_sprintf( hostname, sizeof(hostname), "%s", Info_ValueForKey(info, "hostname")); - return hostname; + // Strip leading whitespace + text = hostname; + while( *text != '\0' && *text == ' ' ) + text++; + + return text; } } case SORT_MAP : -- cgit