Release 3.8.6: module fixes and native timer optimizations

This commit is contained in:
2026-11-06 17:20:18 -04:00
parent b9912256bf
commit e43d93a524
48 changed files with 1966 additions and 2731 deletions
+14 -4
View File
@@ -340,6 +340,14 @@ end
-- Classic cast bar look: dark background, UI-StatusBar fill, the cast bar
-- border and spark, and an icon frame like Improved Castbar's.
local function ApplyBarTheme(bar)
local tint, edge = ShaguTweaks.UITint, ShaguTweaks.UIBorder
bar.border:SetVertexColor(tint and tint.r or 1, tint and tint.g or 1,
tint and tint.b or 1, tint and tint.a or 1)
bar.icon:SetBackdropBorderColor(edge and edge.r or 1, edge and edge.g or 1,
edge and edge.b or 1, edge and edge.a or 1)
end
local function CreateBar(key)
local bar = CreateFrame("StatusBar", "ShaguTweaksSwingTimer_" .. key, S.container)
bar:SetWidth(WIDTH)
@@ -353,7 +361,8 @@ local function CreateBar(key)
bar.bg:SetAllPoints(bar)
bar.bg:SetTexture(0, 0, 0, .5)
bar.border = bar:CreateTexture(nil, "ARTWORK")
-- The StatusBar fill uses ARTWORK; keep the rim above it at every progress.
bar.border = bar:CreateTexture(nil, "OVERLAY")
bar.border:SetTexture("Interface\\CastingBar\\UI-CastingBar-Border")
bar.border:SetWidth(256)
bar.border:SetHeight(64)
@@ -411,15 +420,16 @@ local function CreateBar(key)
tile = true, tileSize = 8, edgeSize = 12,
insets = { left = 2, right = 2, top = 2, bottom = 2 }
})
if ShaguTweaks.DarkMode then
bar.icon:SetBackdropBorderColor(.3, .3, .3, .9)
end
bar.icon.texture = bar.icon:CreateTexture(nil, "BACKGROUND")
bar.icon.texture:SetPoint("CENTER", 0, 0)
bar.icon.texture:SetWidth(24)
bar.icon.texture:SetHeight(24)
bar.icon.texture:SetTexCoord(.08, .92, .08, .92)
ApplyBarTheme(bar)
-- Modules initialize in arbitrary order. Read the final palette when a real
-- timer or mover preview appears, without an idle update or recolor scan.
bar:SetScript("OnShow", function() ApplyBarTheme(this) end)
-- Each bar is dragged on its own while the preview is up.
bar:SetMovable(true)