- better fix to make sure modules always re-register for updates if they need to when they're shown

This commit is contained in:
Parnic
2010-10-30 15:48:54 +00:00
parent dd02a60213
commit fa74303411
3 changed files with 8 additions and 3 deletions

View File

@ -111,6 +111,9 @@ function IceBarElement.prototype:OnHide()
end end
function IceBarElement.prototype:OnShow() function IceBarElement.prototype:OnShow()
if not self:IsFull(self.CurrScale) then
self:ConditionalSetupUpdate()
end
end end
function IceBarElement.prototype:Disable(core) function IceBarElement.prototype:Disable(core)

View File

@ -400,9 +400,6 @@ function IceCastBar.prototype:GetShortRank(rank)
return "" return ""
end end
function IceCastBar.prototype:OnShow()
self:ConditionalSetupUpdate()
end
------------------------------------------------------------------------------- -------------------------------------------------------------------------------

View File

@ -152,6 +152,11 @@ function PlayerMana.prototype:SetupOnUpdate(enable)
end end
end end
function PlayerMana.prototype:OnShow()
if not self:IsFull(self.CurrScale) then
self:SetupOnUpdate(true)
end
end
function PlayerMana.prototype:EnteringVehicle(event, unit, arg2) function PlayerMana.prototype:EnteringVehicle(event, unit, arg2)
if (self.unit == "player" and IceHUD:ShouldSwapToVehicle(unit, arg2)) then if (self.unit == "player" and IceHUD:ShouldSwapToVehicle(unit, arg2)) then