diff --git a/ElvUI_SLE/modules/backgrounds/backgrounds.lua b/ElvUI_SLE/modules/backgrounds/backgrounds.lua index 2f92a84..9874833 100644 --- a/ElvUI_SLE/modules/backgrounds/backgrounds.lua +++ b/ElvUI_SLE/modules/backgrounds/backgrounds.lua @@ -2,7 +2,7 @@ local BG = E:NewModule('BackGrounds', 'AceHook-3.0', 'AceEvent-3.0'); local BGb = CreateFrame('Frame', "BottomBG", E.UIParent); -local BGleft = CreateFrame('Frame', "LeftBG", E.UIParent); +local BGl = CreateFrame('Frame', "LeftBG", E.UIParent); local BGright = CreateFrame('Frame', "RightBG", E.UIParent); local BGaction = CreateFrame('Frame', "ActionBG", E.UIParent); @@ -20,14 +20,14 @@ function BG:FramesCreate() BGb.tex:SetAlpha(0.5) --Left - BGleft:CreateBackdrop(E.private.sle.backgrounds.left.template); - BGleft.backdrop:SetAllPoints(); - BGleft:SetFrameLevel(BGleft:GetFrameLevel() - 1) - BGleft:SetFrameStrata('BACKGROUND'); - BGleft:SetScript("OnShow", function() BGleft:SetFrameStrata('BACKGROUND') end) + BGl:CreateBackdrop(E.private.sle.backgrounds.left.template); + BGl.backdrop:SetAllPoints(); + BGl:SetFrameLevel(BGl:GetFrameLevel() - 1) + BGl:SetFrameStrata('BACKGROUND'); + BGl:SetScript("OnShow", function() BGl:SetFrameStrata('BACKGROUND') end) --Texture - BGleft.tex = BGleft:CreateTexture(nil, 'OVERLAY') - BGleft.tex:SetAlpha(E.db.general.backdropfadecolor.a - 0.7 > 0 and E.db.general.backdropfadecolor.a - 0.7 or 0.5) + BGl.tex = BGl:CreateTexture(nil, 'OVERLAY') + BGl.tex:SetAlpha(E.db.general.backdropfadecolor.a - 0.7 > 0 and E.db.general.backdropfadecolor.a - 0.7 or 0.5) --Right BGright:CreateBackdrop(E.private.sle.backgrounds.right.template); @@ -52,7 +52,7 @@ function BG:FramesCreate() --Hiding BGb:Hide() - BGleft:Hide() + BGl:Hide() BGright:Hide() BGaction:Hide() end @@ -62,8 +62,8 @@ function BG:FramesSize() BGb:SetWidth(E.db.sle.backgrounds.bottom.width) BGb:SetHeight(E.db.sle.backgrounds.bottom.height) - BGleft:SetWidth(E.db.sle.backgrounds.left.width) - BGleft:SetHeight(E.db.sle.backgrounds.left.height) + BGl:SetWidth(E.db.sle.backgrounds.left.width) + BGl:SetHeight(E.db.sle.backgrounds.left.height) BGright:SetWidth(E.db.sle.backgrounds.right.width) BGright:SetHeight(E.db.sle.backgrounds.right.height) @@ -75,7 +75,7 @@ end --Frames points function BG:FramesPositions() BGb:Point("BOTTOM", E.UIParent, "BOTTOM", 0 + E.db.sle.backgrounds.bottom.xoffset, 21 + E.db.sle.backgrounds.bottom.yoffset); - BGleft:Point("BOTTOMRIGHT", E.UIParent, "BOTTOM", -(E.screenwidth/4 + 32)/2 - 1 + E.db.sle.backgrounds.left.xoffset, 21 + E.db.sle.backgrounds.left.yoffset); + BGl:Point("BOTTOMRIGHT", E.UIParent, "BOTTOM", -(E.screenwidth/4 + 32)/2 - 1 + E.db.sle.backgrounds.left.xoffset, 21 + E.db.sle.backgrounds.left.yoffset); BGright:Point("BOTTOMLEFT", E.UIParent, "BOTTOM", (E.screenwidth/4 + 32)/2 + 1 + E.db.sle.backgrounds.right.xoffset, 21 + E.db.sle.backgrounds.right.yoffset); BGaction:Point("BOTTOM", E.UIParent, "BOTTOM", 0 + E.db.sle.backgrounds.action.xoffset, E.screenheight/6 + 9 + E.db.sle.backgrounds.action.yoffset); end @@ -90,9 +90,9 @@ function BG:UpdateTex() BGright.tex:Point('BOTTOMRIGHT', BGright, 'BOTTOMRIGHT', -2, 2) BGright.tex:SetTexture(E.db.sle.backgrounds.right.texture) - BGleft.tex:Point('TOPLEFT', BGleft, 'TOPLEFT', 2, -2) - BGleft.tex:Point('BOTTOMRIGHT', BGleft, 'BOTTOMRIGHT', -2, 2) - BGleft.tex:SetTexture(E.db.sle.backgrounds.left.texture) + BGl.tex:Point('TOPLEFT', BGl, 'TOPLEFT', 2, -2) + BGl.tex:Point('BOTTOMRIGHT', BGl, 'BOTTOMRIGHT', -2, 2) + BGl.tex:SetTexture(E.db.sle.backgrounds.left.texture) BGaction.tex:Point('TOPLEFT', BGaction, 'TOPLEFT', 2, -2) BGaction.tex:Point('BOTTOMRIGHT', BGaction, 'BOTTOMRIGHT', -2, 2) @@ -108,9 +108,9 @@ function BG:FramesVisibility() end if E.db.sle.backgrounds.left.enabled then - BGleft:Show() + BGl:Show() else - BGleft:Hide() + BGl:Hide() end if E.db.sle.backgrounds.right.enabled then