Merge branch 'master' into terencehill/hud_cleanups
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / hud_config.qc
index 148c0ec8e057ca0c523fb1d46a61d310438a8087..48b3c821d20cf35d5f4ec0330dc4c368d99de5b0 100644 (file)
@@ -235,7 +235,7 @@ vector HUD_Panel_CheckMove(vector myPos, vector mySize)
        int i;
        for (i = 0; i < hud_panels_COUNT; ++i) {
                panel = hud_panels[i];
-               if(panel == HUD_PANEL(MAPVOTE)) continue;
+               if(!(panel.panel_configflags & PANEL_CONFIG_MAIN)) continue;
                if(panel == highlightedPanel) continue;
                HUD_Panel_UpdatePosSize();
                if(!panel_enabled) continue;
@@ -332,7 +332,7 @@ vector HUD_Panel_CheckResize(vector mySize, vector resizeorigin) {
        int i;
        for (i = 0; i < hud_panels_COUNT; ++i) {
                panel = hud_panels[i];
-               if(panel == HUD_PANEL(MAPVOTE)) continue;
+               if(!(panel.panel_configflags & PANEL_CONFIG_MAIN)) continue;
                if(panel == highlightedPanel) continue;
                HUD_Panel_UpdatePosSize();
                if(!panel_enabled) continue;
@@ -784,7 +784,7 @@ float HUD_Panel_InputEvent(float bInputType, float nPrimary, float nSecondary)
                        for(i = 0; i < hud_panels_COUNT; ++i)
                        {
                                panel = hud_panels[i];
-                               if(panel == HUD_PANEL(MAPVOTE))
+                               if(!(panel.panel_configflags & PANEL_CONFIG_MAIN))
                                        continue;
                                if (panel == tab_panels[i] || panel == starting_panel)
                                        continue;
@@ -933,7 +933,7 @@ float HUD_Panel_Check_Mouse_Pos(float allow_move)
                j += 1;
 
                panel = hud_panels[i];
-               if(panel == HUD_PANEL(MAPVOTE)) continue;
+               if(!(panel.panel_configflags & PANEL_CONFIG_MAIN)) 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,7 +1015,7 @@ void HUD_Panel_Highlight(float allow_move)
                j += 1;
 
                panel = hud_panels[i];
-               if(panel == HUD_PANEL(MAPVOTE))
+               if(!(panel.panel_configflags & PANEL_CONFIG_MAIN))
                        continue;
                HUD_Panel_UpdatePosSize();