mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 06:40:13 -05:00
- removed a few old CancelScheduledEvent calls on bars that weren't actually scheduling any repeating timers any more and added a few CancelTimers to modules that weren't previously canceling their scheduled timers
- converted CancelScheduledEvent to CancelTimer for modules that are still scheduling repeating timers...not sure why CancelScheduledEvent didn't throw any errors (since i don't see how it exists) but whatever - removed a bunch of "function() self:Thing() end" closures in ScheduleRepeatingTimer calls that didn't need to be there
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
local AceOO = AceLibrary("AceOO-2.0")
|
||||
|
||||
IceCustomMana = AceOO.Class(IceTargetMana)
|
||||
IceCustomMana.prototype.scheduledEvent = nil
|
||||
|
||||
-- Constructor --
|
||||
function IceCustomMana.prototype:init()
|
||||
@ -104,13 +105,13 @@ function IceCustomMana.prototype:Enable(core)
|
||||
|
||||
self:CreateFrame()
|
||||
|
||||
self:ScheduleRepeatingTimer(function() self:Update() end, IceHUD.IceCore:UpdatePeriod())
|
||||
self.scheduledEvent = self:ScheduleRepeatingTimer("Update", IceHUD.IceCore:UpdatePeriod())
|
||||
end
|
||||
|
||||
function IceCustomMana.prototype:Disable(core)
|
||||
IceCustomMana.super.prototype.Disable(self, core)
|
||||
|
||||
self:CancelScheduledEvent(self.elementName)
|
||||
self:CancelTimer(self.scheduledEvent, true)
|
||||
end
|
||||
|
||||
function IceCustomMana.prototype:SetUnit(unit)
|
||||
|
Reference in New Issue
Block a user