mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 22:51:53 -05:00
- fixed text on bars using RegisterUnitWatch to be hidden properly (more fallout from the change in r644 - this was specific to people that had dogtag support disabled)
This commit is contained in:
@ -114,6 +114,10 @@ function IceCustomHealth.prototype:Enable(core)
|
|||||||
self:CreateFrame()
|
self:CreateFrame()
|
||||||
|
|
||||||
self.scheduledEvent = self:ScheduleRepeatingTimer("Update", IceHUD.IceCore:UpdatePeriod())
|
self.scheduledEvent = self:ScheduleRepeatingTimer("Update", IceHUD.IceCore:UpdatePeriod())
|
||||||
|
|
||||||
|
if not IceHUD.IceCore:ShouldUseDogTags() then
|
||||||
|
self.frame:SetScript("OnHide", function() self:SetBottomText1("") self:SetBottomText2("") end)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function IceCustomHealth.prototype:Disable(core)
|
function IceCustomHealth.prototype:Disable(core)
|
||||||
|
@ -258,6 +258,10 @@ function FocusHealth.prototype:Enable(core)
|
|||||||
-- for showing/hiding the frame based on unit visibility
|
-- for showing/hiding the frame based on unit visibility
|
||||||
self.frame:SetAttribute("unit", self.unit)
|
self.frame:SetAttribute("unit", self.unit)
|
||||||
RegisterUnitWatch(self.frame)
|
RegisterUnitWatch(self.frame)
|
||||||
|
|
||||||
|
if not IceHUD.IceCore:ShouldUseDogTags() then
|
||||||
|
self.frame:SetScript("OnHide", function() self:SetBottomText1("") self:SetBottomText2("") end)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function FocusHealth.prototype:CreateBackground()
|
function FocusHealth.prototype:CreateBackground()
|
||||||
|
@ -70,6 +70,10 @@ function PetHealth.prototype:Enable(core)
|
|||||||
self.frame:SetAttribute("unit", self.unit)
|
self.frame:SetAttribute("unit", self.unit)
|
||||||
RegisterUnitWatch(self.frame)
|
RegisterUnitWatch(self.frame)
|
||||||
|
|
||||||
|
if not IceHUD.IceCore:ShouldUseDogTags() then
|
||||||
|
self.frame:SetScript("OnHide", function() self:SetBottomText1("") self:SetBottomText2("") end)
|
||||||
|
end
|
||||||
|
|
||||||
self:CheckPet()
|
self:CheckPet()
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -130,7 +134,7 @@ function PetHealth.prototype:Update(unit)
|
|||||||
self:UpdateBar(self.healthPercentage, color)
|
self:UpdateBar(self.healthPercentage, color)
|
||||||
end
|
end
|
||||||
|
|
||||||
if not IceHUD.IceCore:ShouldUseDogTags() then
|
if not IceHUD.IceCore:ShouldUseDogTags() and self.frame:IsVisible() then
|
||||||
self:SetBottomText1(math.floor(self.healthPercentage * 100))
|
self:SetBottomText1(math.floor(self.healthPercentage * 100))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -646,6 +646,10 @@ function IceTargetHealth.prototype:Enable(core)
|
|||||||
self:Update(self.unit)
|
self:Update(self.unit)
|
||||||
|
|
||||||
RegisterUnitWatch(self.frame)
|
RegisterUnitWatch(self.frame)
|
||||||
|
|
||||||
|
if not IceHUD.IceCore:ShouldUseDogTags() then
|
||||||
|
self.frame:SetScript("OnHide", function() self:SetBottomText1("") self:SetBottomText2("") end)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
@ -813,7 +817,7 @@ function IceTargetHealth.prototype:Update(unit)
|
|||||||
|
|
||||||
self:UpdateBar(self.healthPercentage, self.color)
|
self:UpdateBar(self.healthPercentage, self.color)
|
||||||
|
|
||||||
if not IceHUD.IceCore:ShouldUseDogTags() then
|
if not IceHUD.IceCore:ShouldUseDogTags() and self.frame:IsVisible() then
|
||||||
self:SetBottomText1(math.floor(self.healthPercentage * 100))
|
self:SetBottomText1(math.floor(self.healthPercentage * 100))
|
||||||
|
|
||||||
if self.moduleSettings.abbreviateHealth then
|
if self.moduleSettings.abbreviateHealth then
|
||||||
|
Reference in New Issue
Block a user