- fixed a bug that caused mana frames to stop updating properly in wotlk under certain conditions

This commit is contained in:
Parnic
2008-10-09 05:13:37 +00:00
parent 6a3598e516
commit 6469bd60a9

View File

@ -490,7 +490,10 @@ function IceBarElement.prototype:CreateFrame()
self:CreateTexts()
self.frame:SetScale(self.moduleSettings.scale)
if not string.find(self.elementName, "MirrorBar") then
-- never register the OnUpdate for the mirror bar since it's handled internally
-- in addition, do not register OnUpdate if predictedPower is set and this is the player mana or target mana bar
if not string.find(self.elementName, "MirrorBar")
and (not GetCVarBool("predictedPower") or (not string.find(self.elementName, "PlayerMana") and not string.find(self.elementName, "TargetMana"))) then
self.frame:SetScript("OnUpdate", function() self:MyOnUpdate() end)
end
end