From 658679108c8c008862b023fbac1490d308ecf521 Mon Sep 17 00:00:00 2001 From: Cinecom <42314202+Cinecom@users.noreply.github.com> Date: Thu, 2 Jan 2025 10:23:48 +0100 Subject: [PATCH] Update 2.0.2 Minor bug fix --- Main.lua | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/Main.lua b/Main.lua index 66e985f..dc396f8 100644 --- a/Main.lua +++ b/Main.lua @@ -58,9 +58,12 @@ ConsumesManager_EventFrame:SetScript("OnEvent", function() + local isDefaultBankVisible = BankFrame and BankFrame:IsVisible() + local isOneBankVisible = OneBankFrame and OneBankFrame:IsVisible() + if event == "BANKFRAME_OPENED" then isBankOpen = true - elseif event == "BANKFRAME_CLOSED" then + elseif not (isDefaultBankVisible or isOneBankVisible) then isBankOpen = false elseif event == "MAIL_SHOW" then isMailOpen = true @@ -428,11 +431,8 @@ function ConsumesManager_ShowMainWindow() -- Update Settings content ConsumesManager_UpdateSettingsContent() - end - - function ConsumesManager_ShowTab(tabIndex) if not ConsumesManager_MainFrame or not ConsumesManager_MainFrame.tabs then return end @@ -2179,7 +2179,6 @@ end - -- Settings Window ----------------------------------------------------------------------------------- function ConsumesManager_CreateSettingsContent(parentFrame) -- Scroll Frame Setup @@ -2900,8 +2899,6 @@ end - - -- Global Functions ----------------------------------------------------------------------------- function ConsumesManager_UpdateUseButtons() if not ConsumesManager_MainFrame or not ConsumesManager_MainFrame.tabs or not ConsumesManager_MainFrame.tabs[1] then @@ -3513,7 +3510,6 @@ function ConsumesManager_ScanPlayerInventory() end function ConsumesManager_ScanPlayerBank() - if not isBankOpen then return end local delayFrameBank = CreateFrame("Frame")