Skip to content

Commit

Permalink
Progress
Browse files Browse the repository at this point in the history
  • Loading branch information
InfusOnWoW committed Mar 28, 2021
1 parent 62b2777 commit 7f10e8d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 41 deletions.
1 change: 0 additions & 1 deletion WeakAuras/AuraEnvironment.lua
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,6 @@ local FakeWeakAurasMixin = {
UpdateGroupOrders = true,
UpdateThumbnail = true,
validate = true,
getDefaultGlow = true,
},
blockedTables = {
AuraWarnings = true,
Expand Down
38 changes: 0 additions & 38 deletions WeakAuras/SubRegionTypes/Glow.lua
Original file line number Diff line number Diff line change
Expand Up @@ -353,44 +353,6 @@ local function modify(parent, region, parentData, data, first)
region:SetScript("OnSizeChanged", region.UpdateSize)
end

-- This is used by the templates to add glow
function WeakAuras.getDefaultGlow(regionType)
if regionType == "aurabar" then
return {
["type"] = "subglow",
glow = false,
useGlowColor = false,
glowColor = {1, 1, 1, 1},
glowType = "Pixel",
glowLines = 8,
glowFrequency = 0.25,
glowLength = 10,
glowThickness = 1,
glowScale = 1,
glowBorder = false,
glowXOffset = 0,
glowYOffset = 0,
glow_anchor = "bar"
}
elseif regionType == "icon" then
return {
["type"] = "subglow",
glow = false,
useGlowColor = false,
glowColor = {1, 1, 1, 1},
glowType = "buttonOverlay",
glowLines = 8,
glowFrequency = 0.25,
glowLength = 10,
glowThickness = 1,
glowScale = 1,
glowBorder = false,
glowXOffset = 0,
glowYOffset = 0,
}
end
end

local function supports(regionType)
return regionType == "icon"
or regionType == "aurabar"
Expand Down
6 changes: 4 additions & 2 deletions WeakAurasTemplates/TriggerTemplates.lua
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ local function changes(property, regionType)
};
end

-- TODO check that this works
-- TODO check that templates filtering condition changes work
local defaults = TemplatePrivate.Private.GetDefaultsForRegion(regionType, "template")
if defaults[property] == nil then
return nil;
Expand Down Expand Up @@ -501,7 +501,9 @@ local function subTypesFor(item, regionType)
cd = 134377,
cd2 = 134376,
};
local subglow = WeakAuras.getDefaultGlow(regionType)
-- TODO check that this code works
local subglow = TemplatePrivate.Private.GetDefaultsForSubRegion("glow", regionType, "template")
-- TODO this looks hacky
local subglowindex = (regionType == "icon" or regionType == "aurabar") and 1
local data = {}
local dataGlow = {
Expand Down

0 comments on commit 7f10e8d

Please sign in to comment.