mirror of
https://github.com/Bluewhale1337/ElvUIModernized.git
synced 2026-07-27 08:24:44 +00:00
update
This commit is contained in:
@@ -2,6 +2,9 @@
|
||||
local ns = oUF
|
||||
local oUF = ns.oUF
|
||||
|
||||
local pairs = pairs
|
||||
|
||||
local UIFrameFadeIn, UIFrameFadeOut = UIFrameFadeIn, UIFrameFadeOut
|
||||
local UnitAffectingCombat = UnitAffectingCombat
|
||||
local UnitHealth, UnitHealthMax = UnitHealth, UnitHealthMax
|
||||
local UnitExists = UnitExists
|
||||
@@ -10,7 +13,7 @@ local frames, allFrames = {}, {}
|
||||
local showStatus
|
||||
|
||||
local CheckForReset = function()
|
||||
for frame, unit in pairs(allFrames) do
|
||||
for frame in pairs(allFrames) do
|
||||
if frame.fadeInfo and frame.fadeInfo.reset then
|
||||
frame:SetAlpha(1)
|
||||
frame.fadeInfo.reset = nil
|
||||
@@ -19,7 +22,6 @@ local CheckForReset = function()
|
||||
end
|
||||
|
||||
local FadeFramesInOut = function(fade, unit)
|
||||
local E = unpack(ElvUI)
|
||||
for frame, unit in pairs(frames) do
|
||||
if not UnitExists(unit) then return end
|
||||
if fade then
|
||||
@@ -31,7 +33,7 @@ local FadeFramesInOut = function(fade, unit)
|
||||
UIFrameFadeOut(frame, 0.15)
|
||||
frame.fadeInfo.finishedFunc = CheckForReset
|
||||
else
|
||||
showStatus = false;
|
||||
showStatus = false
|
||||
return
|
||||
end
|
||||
end
|
||||
@@ -48,8 +50,6 @@ local Update = function(self, arg1, arg2)
|
||||
return
|
||||
end
|
||||
|
||||
local E = unpack(ElvUI)
|
||||
|
||||
if not frames[self] then
|
||||
UIFrameFadeIn(self, 0.15)
|
||||
self.fadeInfo.reset = true
|
||||
@@ -81,7 +81,7 @@ local Enable = function(self, unit)
|
||||
allFrames[self] = self.unit
|
||||
|
||||
if unit == "player" then
|
||||
showStatus = false;
|
||||
showStatus = false
|
||||
end
|
||||
|
||||
self:RegisterEvent("PLAYER_ENTERING_WORLD", Update)
|
||||
@@ -95,8 +95,8 @@ local Enable = function(self, unit)
|
||||
self:RegisterEvent("UNIT_MODEL_CHANGED", Update)
|
||||
|
||||
if not self.CombatFadeHooked then
|
||||
HookScript(self, "OnEnter", function(self) Update(self, true) end)
|
||||
HookScript(self, "OnLeave", function(self) Update(self, false) end)
|
||||
HookScript(self, "OnEnter", function() Update(self, true) end)
|
||||
HookScript(self, "OnLeave", function() Update(self, false) end)
|
||||
self.CombatFadeHooked = true
|
||||
end
|
||||
return true
|
||||
|
||||
@@ -83,7 +83,7 @@ function UF:Configure_ClassBar(frame)
|
||||
E:Size(bars.Holder, db.classbar.detachedWidth, db.classbar.height)
|
||||
|
||||
if not bars.Holder.mover then
|
||||
bars:SerWidth(CLASSBAR_WIDTH)
|
||||
bars:SetWidth(CLASSBAR_WIDTH)
|
||||
bars:SetHeight(frame.CLASSBAR_HEIGHT - ((frame.BORDER+frame.SPACING)*2))
|
||||
bars:ClearAllPoints()
|
||||
E:Point(bars, "BOTTOMLEFT", bars.Holder, "BOTTOMLEFT", frame.BORDER + frame.SPACING, frame.BORDER + frame.SPACING)
|
||||
|
||||
Reference in New Issue
Block a user