Fix open prefs taint

This commit is contained in:
Robin Hüskes 2022-11-28 23:11:28 +01:00
parent d89fb5645a
commit 0d483a13a0
2 changed files with 7 additions and 4 deletions

View File

@ -8,6 +8,7 @@ local function bclick(swap)
if(not InCombatLockdown() and GarrisonLandingPage) then
if(GarrisonLandingPage:IsShown()) then
GarrisonLandingPage_Toggle()
GameMenuFrame:Hide()
if(not swap) then
return
end
@ -19,6 +20,7 @@ local function bclick(swap)
if(not GarrisonLandingPage.garrTypeID) then
-- print("still no garrType")
GarrisonLandingPage_Toggle()
GameMenuFrame:Hide()
return
end
end
@ -74,7 +76,8 @@ local function OnClick(_, button)
if(not InCombatLockdown()) then
if(SettingsPanel) then
if(SettingsPanel:IsVisible()) then
SettingsPanel:Hide()
HideUIPanel(SettingsPanel)
HideUIPanel(GameMenuFrame)
else
Settings.OpenToCategory(childName)
end

View File

@ -95,9 +95,9 @@ function events:PLAYER_ENTERING_WORLD()
if(not IsAddOnLoaded("Blizzard_GarrisonUI")) then
UIParentLoadAddOn("Blizzard_GarrisonUI")
end
if(db['hideStandard'] and GarrisonLandingPageMinimapButton) then
GarrisonLandingPageMinimapButton:UnregisterAllEvents()
GarrisonLandingPageMinimapButton:Hide()
if(db['hideStandard'] and ExpansionLandingPageMinimapButton) then
ExpansionLandingPageMinimapButton:UnregisterAllEvents()
ExpansionLandingPageMinimapButton:Hide()
end
child:switchDisplay(db['garrisonHideCombat'])
end