From 9aa1e518f1babaed2308b840c2bfa9a8dd530f75 Mon Sep 17 00:00:00 2001 From: Pawel Date: Sat, 2 Apr 2016 20:19:00 +0200 Subject: [PATCH] v1.7 - page action bar update fixes --- TDDps.lua | 12 ++++++++---- TDDps.toc | 2 +- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/TDDps.lua b/TDDps.lua index 18d2f7e..bd4915f 100644 --- a/TDDps.lua +++ b/TDDps.lua @@ -54,8 +54,9 @@ function TDDps_InitAddon() TDDps_Frame:RegisterEvent('PLAYER_TARGET_CHANGED'); TDDps_Frame:RegisterEvent('PLAYER_TALENT_UPDATE'); + TDDps_Frame:RegisterEvent('ACTIONBAR_SLOT_CHANGED'); TDDps_Frame:RegisterEvent('PLAYER_REGEN_DISABLED'); - TDDps_Frame:RegisterEvent('PLAYER_REGEN_ENABLED'); +-- TDDps_Frame:RegisterEvent('PLAYER_REGEN_ENABLED'); TDDps_Frame:SetScript('OnEvent', TDDps_OnEvent); @@ -109,6 +110,11 @@ end -- Event Script, Target Change, Specializaton Change ---------------------------------------------- function TDDps_OnEvent(self, event) + if event == 'PLAYER_TALENT_UPDATE' then + TDDps_DisableAddon(); + elseif event == 'ACTIONBAR_SLOT_CHANGED' then + TDDps_DisableAddon(); + end if TDDps_Frame.rotationEnabled then if event == 'PLAYER_TARGET_CHANGED' then if (UnitIsFriend('player', 'target')) then @@ -118,9 +124,7 @@ function TDDps_OnEvent(self, event) end end end - if event == 'PLAYER_TALENT_UPDATE' then - TDDps_DisableAddon(); - elseif event == 'PLAYER_REGEN_DISABLED' and TDDps_Options.onCombatEnter and not TDDps_Frame.rotationEnabled then + if event == 'PLAYER_REGEN_DISABLED' and TDDps_Options.onCombatEnter and not TDDps_Frame.rotationEnabled then print(_tdSuccess .. TDDpsName .. ': Auto enable on combat!'); TDDps_Frame.rotationEnabled = true; TDDps_LoadModule(); diff --git a/TDDps.toc b/TDDps.toc index 3f50a04..b645ed9 100644 --- a/TDDps.toc +++ b/TDDps.toc @@ -1,6 +1,6 @@ ## Title: TDDps ## Notes: Rotation helper framework. -## Version: 1.6 +## Version: 1.7 ## Author: Kaminaris ## Interface: 60200 ## SavedVariables: TDDps_Options -- 1.7.9.5