[openjk] 11/32: Fix eax_icon not hiding in MP when EAX unavailable
Simon McVittie
smcv at debian.org
Sun Mar 12 18:03:03 UTC 2017
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to branch debian/master
in repository openjk.
commit a3588914317513258ab3d03efcc23af6cecd0b8b
Author: Ensiform <ensiform at gmail.com>
Date: Mon Mar 6 11:40:16 2017 -0600
Fix eax_icon not hiding in MP when EAX unavailable
---
code/ui/ui_shared.cpp | 2 +-
codemp/ui/ui_shared.c | 7 ++++++-
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/code/ui/ui_shared.cpp b/code/ui/ui_shared.cpp
index fe0c64c..2ab8b1a 100644
--- a/code/ui/ui_shared.cpp
+++ b/code/ui/ui_shared.cpp
@@ -1048,7 +1048,7 @@ static void Item_ApplyHacks( itemDef_t *item ) {
}
}
- if ( item->type == ITEM_TYPE_TEXT && item->window.name && !Q_stricmp( item->window.name, "eax_icon") && item->cvarTest && !Q_stricmp( item->cvarTest, "s_UseOpenAL" ) && item->enableCvar && item->cvarFlags & CVAR_HIDE ) {
+ if ( item->type == ITEM_TYPE_TEXT && item->window.name && !Q_stricmp( item->window.name, "eax_icon") && item->cvarTest && !Q_stricmp( item->cvarTest, "s_UseOpenAL" ) && item->enableCvar && (item->cvarFlags & CVAR_HIDE) ) {
if( item->parent )
{
menuDef_t *parent = (menuDef_t *)item->parent;
diff --git a/codemp/ui/ui_shared.c b/codemp/ui/ui_shared.c
index b529d26..0acc689 100644
--- a/codemp/ui/ui_shared.c
+++ b/codemp/ui/ui_shared.c
@@ -6349,6 +6349,11 @@ void Item_Paint(itemDef_t *item)
}
}
+ if (item->disabled && item->disabledHidden)
+ {
+ return;
+ }
+
if (item->cvarFlags & (CVAR_SHOW | CVAR_HIDE)) {
if (!Item_EnableShowViaCvar(item, CVAR_SHOW)) {
return;
@@ -8456,7 +8461,7 @@ static void Item_ApplyHacks( itemDef_t *item ) {
}
}
- if ( item->type == ITEM_TYPE_TEXT && item->window.name && !Q_stricmp( item->window.name, "eax_icon") && item->cvarTest && !Q_stricmp( item->cvarTest, "s_UseOpenAL" ) && item->enableCvar && item->cvarFlags & CVAR_HIDE ) {
+ if ( item->type == ITEM_TYPE_TEXT && item->window.name && !Q_stricmp( item->window.name, "eax_icon") && item->cvarTest && !Q_stricmp( item->cvarTest, "s_UseOpenAL" ) && item->enableCvar && (item->cvarFlags & CVAR_HIDE) ) {
if( item->parent )
{
menuDef_t *parent = (menuDef_t *)item->parent;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/openjk.git
More information about the Pkg-games-commits
mailing list