From: terencehill Date: Thu, 30 Jul 2015 09:37:29 +0000 (+0200) Subject: Make sure mapvote panel doesn't interact with the hud editor as it's not editable X-Git-Tag: xonotic-v0.8.1~22^2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=8a622e224fa41ab6e697734538d839b1242aac07;p=xonotic%2Fxonotic-data.pk3dir.git Make sure mapvote panel doesn't interact with the hud editor as it's not editable --- diff --git a/qcsrc/client/hud_config.qc b/qcsrc/client/hud_config.qc index 4b55bb40e..29488d6de 100644 --- a/qcsrc/client/hud_config.qc +++ b/qcsrc/client/hud_config.qc @@ -232,6 +232,7 @@ vector HUD_Panel_CheckMove(vector myPos, vector mySize) int i; for (i = 0; i < HUD_PANEL_NUM; ++i) { panel = hud_panel[i]; + if(panel == HUD_PANEL(MAPVOTE)) continue; if(panel == highlightedPanel) continue; HUD_Panel_UpdatePosSize(); if(!panel_enabled) continue; @@ -328,6 +329,7 @@ vector HUD_Panel_CheckResize(vector mySize, vector resizeorigin) { int i; for (i = 0; i < HUD_PANEL_NUM; ++i) { panel = hud_panel[i]; + if(panel == HUD_PANEL(MAPVOTE)) continue; if(panel == highlightedPanel) continue; HUD_Panel_UpdatePosSize(); if(!panel_enabled) continue; @@ -787,6 +789,8 @@ float HUD_Panel_InputEvent(float bInputType, float nPrimary, float nSecondary) for(i = 0; i < HUD_PANEL_NUM; ++i) { panel = hud_panel[i]; + if(panel == HUD_PANEL(MAPVOTE)) + continue; if (panel == tab_panels[i] || panel == starting_panel) continue; HUD_Panel_UpdatePosSize(); @@ -934,6 +938,7 @@ float HUD_Panel_Check_Mouse_Pos(float allow_move) j += 1; panel = hud_panel[i]; + if(panel == HUD_PANEL(MAPVOTE)) continue; HUD_Panel_UpdatePosSize(); float border = max(8, panel_bg_border); // FORCED border so a small border size doesn't mean you can't resize @@ -1015,6 +1020,8 @@ void HUD_Panel_Highlight(float allow_move) j += 1; panel = hud_panel[i]; + if(panel == HUD_PANEL(MAPVOTE)) + continue; HUD_Panel_UpdatePosSize(); float border = max(8, panel_bg_border); // FORCED border so a small border size doesn't mean you can't resize