From 41b869fd0471a075c7ef3333e6119aec033b6cbb Mon Sep 17 00:00:00 2001 From: Severin Meyer Date: Sun, 26 Jul 2015 13:31:33 +0200 Subject: [PATCH] Remove GFX_SERVERLIST_ICON. There is no reason why themes should use a custom icon name prefix, and no existing theme does. --- qcsrc/menu/skin-customizables.inc | 1 - qcsrc/menu/xonotic/serverlist.qc | 14 +++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/qcsrc/menu/skin-customizables.inc b/qcsrc/menu/skin-customizables.inc index bf29683f6..413f10338 100644 --- a/qcsrc/menu/skin-customizables.inc +++ b/qcsrc/menu/skin-customizables.inc @@ -247,7 +247,6 @@ SKINBEGIN SKINVECTOR(COLOR_SERVERLIST_FAVORITE, '1 1 1'); SKINFLOAT(ALPHA_SERVERLIST_IMPOSSIBLE, 0.7); SKINVECTOR(COLOR_SERVERLIST_IMPOSSIBLE, '0.3 0.3 0.3'); - SKINSTRING(GFX_SERVERLIST_ICON, "icon"); SKINFLOAT(ALPHA_SERVERLIST_ICON_NONPURE, 0.5); // item: server info diff --git a/qcsrc/menu/xonotic/serverlist.qc b/qcsrc/menu/xonotic/serverlist.qc index 585bfcd5d..33203c52b 100644 --- a/qcsrc/menu/xonotic/serverlist.qc +++ b/qcsrc/menu/xonotic/serverlist.qc @@ -1164,16 +1164,16 @@ void XonoticServerList_drawListBoxItem(entity me, int i, vector absSize, bool is if(me.seenIPv4 && me.seenIPv6) { if(isv6) - draw_Picture(iconPos, strcat(SKINGFX_SERVERLIST_ICON, "_ipv6"), iconSize, '1 1 1', 1); + draw_Picture(iconPos, "icon_ipv6", iconSize, '1 1 1', 1); else if(isv4) - draw_Picture(iconPos, strcat(SKINGFX_SERVERLIST_ICON, "_ipv4"), iconSize, '1 1 1', 1); + draw_Picture(iconPos, "icon_ipv4", iconSize, '1 1 1', 1); } iconPos.x += iconSize.x; // AES if(q > 0) - draw_Picture(iconPos, strcat(SKINGFX_SERVERLIST_ICON, "_aeslevel", ftos(q)), iconSize, '1 1 1', 1); + draw_Picture(iconPos, strcat("icon_aeslevel", ftos(q)), iconSize, '1 1 1', 1); iconPos.x += iconSize.x; @@ -1181,13 +1181,13 @@ void XonoticServerList_drawListBoxItem(entity me, int i, vector absSize, bool is if(modname == "Xonotic") { if(pure == 0) - draw_Picture(iconPos, strcat(SKINGFX_SERVERLIST_ICON, "_pure1"), iconSize, '1 1 1', 1); + draw_Picture(iconPos, "icon_pure1", iconSize, '1 1 1', 1); } else { - string icon = strcat(SKINGFX_SERVERLIST_ICON, "_mod_", modname); + string icon = strcat("icon_mod_", modname); if(draw_PictureSize(icon) == '0 0 0') - icon = strcat(SKINGFX_SERVERLIST_ICON, "_mod_"); + icon = "icon_mod_"; if(pure == 0) draw_Picture(iconPos, icon, iconSize, '1 1 1', 1); @@ -1199,7 +1199,7 @@ void XonoticServerList_drawListBoxItem(entity me, int i, vector absSize, bool is // Stats if(sflags >= 0 && (sflags & SERVERFLAG_PLAYERSTATS)) - draw_Picture(iconPos, strcat(SKINGFX_SERVERLIST_ICON, "_stats1"), iconSize, '1 1 1', 1); + draw_Picture(iconPos, "icon_stats1", iconSize, '1 1 1', 1); // -------------- // RENDER TEXT -- 2.39.2