from retail

This commit is contained in:
NoM0Re
2025-01-26 21:24:18 +01:00
parent 1793d7ac19
commit f9bf9c3c16
25 changed files with 1467 additions and 500 deletions
+10 -8
View File
@@ -22,7 +22,7 @@ local default = function(parentType)
}
if parentType == "aurabar" then
options["glowType"] = "Pixel"
options["glow_anchor"] = "bar"
options["anchor_area"] = "bar"
end
return options
end
@@ -314,12 +314,6 @@ end
local function modify(parent, region, parentData, data, first)
region:SetParent(parent)
region.parentRegionType = parentData.regionType
if parentData.regionType == "aurabar" then
parent:AnchorSubRegion(region, "area", data.glow_anchor)
else
parent:AnchorSubRegion(region, "area", data.glowType == "buttonOverlay" and "region")
end
region.parent = parent
region.parentType = parentData.regionType
@@ -338,6 +332,14 @@ local function modify(parent, region, parentData, data, first)
region:SetVisible(data.glow)
region:SetScript("OnSizeChanged", region.UpdateSize)
region.Anchor = function()
if parentData.regionType == "aurabar" then
parent:AnchorSubRegion(region, "area", data.anchor_area)
else
parent:AnchorSubRegion(region, "area", (data.glowType == "buttonOverlay" or data.glowType == "Proc") and "region")
end
end
end
-- This is used by the templates to add glow
@@ -357,7 +359,7 @@ function Private.getDefaultGlow(regionType)
glowBorder = false,
glowXOffset = 0,
glowYOffset = 0,
glow_anchor = "bar"
anchor_area = "bar"
}
else
return {