From 16847def99fb4623e76958a00de0e949e94ccf87 Mon Sep 17 00:00:00 2001 From: torhal Date: Thu, 12 Nov 2009 07:51:52 +0000 Subject: [PATCH] Changed OnClick script for the mode_button to automatically switch to and then scan the appropriate tradeskill. If the window was not visible before switching, hide it. No more annoying "You have not yet scanned this tradeskill" message. --- ARLFrame.lua | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ARLFrame.lua b/ARLFrame.lua index 453fe6b..7a571f2 100644 --- a/ARLFrame.lua +++ b/ARLFrame.lua @@ -3184,6 +3184,13 @@ function addon:InitializeFrame() playerData.playerProfession = SortedProfessions[currentProfIndex].name currentProfession = playerData.playerProfession + local is_shown = TradeSkillFrame:IsVisible() + CastSpellByName(currentProfession) + addon:Scan() + + if not is_shown then + TradeSkillFrame:Hide() + end -- Lets get the new skill level -- Expand all headers first -- 1.7.9.5