Commented out addon:TRADE_SKILL_UPDATE() and the corresponding updater frame - not only does the event fire for others (without saying who it fires for), but calling addon:Scan() results in it firing, which calls addon:Scan() a second time.
James D. Callahan III [06-02-10 - 04:36]
Commented out addon:TRADE_SKILL_UPDATE() and the corresponding updater frame - not only does the event fire for others (without saying who it fires for), but calling addon:Scan() results in it firing, which calls addon:Scan() a second time.
diff --git a/ARL.lua b/ARL.lua
index 727c919..4a61cfd 100644
--- a/ARL.lua
+++ b/ARL.lua
@@ -788,29 +788,33 @@ function addon:TRADE_SKILL_CLOSE()
end
do
- local last_update = 0
- local updater = CreateFrame("Frame", nil, UIParent)
-
- updater:Hide()
- updater:SetScript("OnUpdate",
- function(self, elapsed)
- last_update = last_update + elapsed
-
- if last_update >= 0.5 then
- addon:Scan(false, true)
- self:Hide()
- end
- end)
-
- function addon:TRADE_SKILL_UPDATE()
- if not self.Frame:IsVisible() then
- return
- end
-
- if not updater:IsVisible() then
- last_update = 0
- updater:Show()
- end
+ -- local last_update = 0
+ -- local updater = CreateFrame("Frame", nil, UIParent)
+
+ -- updater:Hide()
+ -- updater:SetScript("OnUpdate",
+ -- function(self, elapsed)
+ -- last_update = last_update + elapsed
+
+ -- addon:Debug("Running the updater's OnUpdate")
+ -- if last_update >= 0.5 then
+ -- addon:Scan(false, true)
+ -- self:Hide()
+ -- end
+ -- end)
+
+ function addon:TRADE_SKILL_UPDATE(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10)
+ -- if not self.Frame:IsVisible() then
+ -- return
+ -- end
+
+ -- addon:Debug("Args are: %s, %s, %s, %s, %s, %s, %s, %s, %s, %s", tostring(arg1), tostring(arg2), tostring(arg3), tostring(arg4),
+ -- tostring(arg5), tostring(arg6), tostring(arg7), tostring(arg8), tostring(arg9), tostring(arg10))
+
+ -- if not updater:IsVisible() then
+ -- last_update = 0
+ -- updater:Show()
+ -- end
end
end