fix taint (Gladdy show in combat)
This commit is contained in:
parent
c2fec39202
commit
f92b3a4964
@ -104,7 +104,7 @@ function Gladdy:CreateFrame()
|
|||||||
self.anchor:Hide()
|
self.anchor:Hide()
|
||||||
end
|
end
|
||||||
|
|
||||||
self.frame:Hide()
|
self.frame:SetAlpha(0)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Gladdy:UpdateFrame()
|
function Gladdy:UpdateFrame()
|
||||||
@ -271,7 +271,7 @@ end
|
|||||||
|
|
||||||
function Gladdy:HideFrame()
|
function Gladdy:HideFrame()
|
||||||
if (self.frame) then
|
if (self.frame) then
|
||||||
self.frame:Hide()
|
self.frame:SetAlpha(0)
|
||||||
self.frame.testing = nil
|
self.frame.testing = nil
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -297,7 +297,7 @@ function Gladdy:ToggleFrame(i)
|
|||||||
self.curBracket = i
|
self.curBracket = i
|
||||||
self:UpdateFrame()
|
self:UpdateFrame()
|
||||||
self:Test()
|
self:Test()
|
||||||
self.frame:Show()
|
self.frame:SetAlpha(1)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -251,10 +251,13 @@ function Gladdy:OnEnable()
|
|||||||
self:RegisterEvent("UPDATE_BATTLEFIELD_STATUS")
|
self:RegisterEvent("UPDATE_BATTLEFIELD_STATUS")
|
||||||
self:RegisterEvent("PLAYER_ENTERING_WORLD")
|
self:RegisterEvent("PLAYER_ENTERING_WORLD")
|
||||||
|
|
||||||
|
self:CreateFrame()
|
||||||
for i = 1, 5 do
|
for i = 1, 5 do
|
||||||
self:CreateButton(i)
|
self:CreateButton(i)
|
||||||
end
|
end
|
||||||
|
self.curBracket = 5
|
||||||
self:UpdateFrame()
|
self:UpdateFrame()
|
||||||
|
self:Reset()
|
||||||
|
|
||||||
if (IsAddOnLoaded("Clique")) then
|
if (IsAddOnLoaded("Clique")) then
|
||||||
ClickCastFrames = ClickCastFrames or {}
|
ClickCastFrames = ClickCastFrames or {}
|
||||||
@ -425,8 +428,8 @@ function Gladdy:JoinedArena()
|
|||||||
self.curBracket = 2
|
self.curBracket = 2
|
||||||
end
|
end
|
||||||
|
|
||||||
self:SendMessage("JOINED_ARENA")
|
Gladdy:SendMessage("JOINED_ARENA")
|
||||||
self.frame:Show()
|
self.frame:SetAlpha(1)
|
||||||
for i=1, self.curBracket do
|
for i=1, self.curBracket do
|
||||||
self.buttons["arena" .. i]:SetAlpha(1)
|
self.buttons["arena" .. i]:SetAlpha(1)
|
||||||
end
|
end
|
||||||
|
@ -53,8 +53,8 @@ BINDING_NAME_GLADDYBUTTON3_BUTTON5 = L["Button5 Click Enemy 3"]
|
|||||||
BINDING_NAME_GLADDYBUTTON4_BUTTON5 = L["Button5 Click Enemy 4"]
|
BINDING_NAME_GLADDYBUTTON4_BUTTON5 = L["Button5 Click Enemy 4"]
|
||||||
BINDING_NAME_GLADDYBUTTON5_BUTTON5 = L["Button5 Click Enemy 5"]
|
BINDING_NAME_GLADDYBUTTON5_BUTTON5 = L["Button5 Click Enemy 5"]
|
||||||
|
|
||||||
function Clicks:Initialise()
|
function Clicks:Initialize()
|
||||||
self:RegisterMessage("JOINED_ARENA")
|
--
|
||||||
end
|
end
|
||||||
|
|
||||||
function Clicks:Reset()
|
function Clicks:Reset()
|
||||||
@ -62,21 +62,14 @@ function Clicks:Reset()
|
|||||||
end
|
end
|
||||||
|
|
||||||
function Clicks:ResetUnit(unit)
|
function Clicks:ResetUnit(unit)
|
||||||
local button = Gladdy.buttons[unit]
|
--
|
||||||
if (not button) then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
for k, v in pairs(Gladdy.db.attributes) do
|
|
||||||
button.secure:SetAttribute(v.modifier .. "macrotext" .. v.button, "")
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
function Clicks:Test()
|
function Clicks:UpdateFrame(unit)
|
||||||
Clicks:JOINED_ARENA()
|
self:SetupAttributes(unit)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Clicks:JOINED_ARENA()
|
function Clicks:UpdateFrameOnce()
|
||||||
for k, v in pairs(Gladdy.buttons) do
|
for k, v in pairs(Gladdy.buttons) do
|
||||||
local left = GetBindingKey(("GLADDYBUTTON%d_LEFT"):format(v.id))
|
local left = GetBindingKey(("GLADDYBUTTON%d_LEFT"):format(v.id))
|
||||||
local right = GetBindingKey(("GLADDYBUTTON%d_RIGHT"):format(v.id))
|
local right = GetBindingKey(("GLADDYBUTTON%d_RIGHT"):format(v.id))
|
||||||
@ -222,8 +215,3 @@ function Clicks:GetOptions()
|
|||||||
end
|
end
|
||||||
return options
|
return options
|
||||||
end
|
end
|
||||||
|
|
||||||
function Clicks:UpdateFrame(unit)
|
|
||||||
self:SetupAttributes(unit)
|
|
||||||
self:JOINED_ARENA()
|
|
||||||
end
|
|
Loading…
Reference in New Issue
Block a user