Skip to content

Commit a11c872

Browse files
committed
Fix profile direction switch, name truncation offline, summon icon stuck, icon alpha not persisting
- ApplyHeaderSettings() now called in FullProfileRefresh so grow direction changes apply on profile switch - Offline name text now respects truncation settings (was bypassing truncation logic) - Summon icons refresh on GROUP_ROSTER_UPDATE and zone changes to clear stale icons - Icon appearance functions (role, leader, raid target, ready check) now use db alpha instead of hardcoded 1.0
1 parent 0cc408e commit a11c872

5 files changed

Lines changed: 43 additions & 13 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
* Fix resource bar border not showing after login/reload — was calling non-existent function
1515
* Fix heal absorb bar showing smaller than actual absorb amount — calculator was subtracting incoming heals from absorb value
1616
* Replace pcall wrappers with nil checks in absorb/heal calculator hot paths for better performance
17+
* Fix profile direction switch not applying — switching to a profile with a different grow direction now correctly reconfigures header orientation
18+
* Fix name text truncation not applied to offline players — offline frames showed full names ignoring the truncation setting
19+
* Fix summon icon permanently stuck on frames after M+ start or group leave — summon icons now refresh on roster and zone changes
20+
* Fix icon alpha settings (role, leader, raid target, ready check) reverting to 100% after releasing the slider — appearance system was ignoring user-set alpha values
1721

1822
### New Features
1923
* Debug Console — persistent debug logging system with in-game viewer (`/df debug` to toggle, `/df console` to view). Logs persist across reloads with category filtering, severity levels, and clipboard export

Core.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4223,6 +4223,13 @@ function DF:FullProfileRefresh()
42234223
end
42244224
end
42254225

4226+
-- === RECONFIGURE HEADER ORIENTATION ===
4227+
-- Must be called before layout updates so headers use the new profile's
4228+
-- growDirection, growthAnchor, and selfPosition settings
4229+
if DF.ApplyHeaderSettings then
4230+
DF:ApplyHeaderSettings()
4231+
end
4232+
42264233
-- === UPDATE LAYOUTS ===
42274234
-- Update party layout (this handles positioning, visibility, etc.)
42284235
if DF.UpdateAllFrames then

Features/ElementAppearance.lua

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -631,11 +631,11 @@ function DF:UpdateRoleIconAppearance(frame)
631631
local deadOrOffline = IsDeadOrOffline(frame)
632632
local inRange = GetInRange(frame)
633633

634-
local alpha = 1.0
634+
local alpha = db.roleIconAlpha or 1.0
635635
if deadOrOffline and db.fadeDeadFrames then
636-
alpha = db.fadeDeadIcons or 1.0
636+
alpha = (db.fadeDeadIcons or 1.0) * (db.roleIconAlpha or 1.0)
637637
end
638-
638+
639639
if db.oorEnabled then
640640
local oorAlpha = db.oorIconsAlpha or 0.5
641641
ApplyOORAlpha(frame.roleIcon, inRange, alpha, oorAlpha)
@@ -656,11 +656,11 @@ function DF:UpdateLeaderIconAppearance(frame)
656656
local deadOrOffline = IsDeadOrOffline(frame)
657657
local inRange = GetInRange(frame)
658658

659-
local alpha = 1.0
659+
local alpha = db.leaderIconAlpha or 1.0
660660
if deadOrOffline and db.fadeDeadFrames then
661-
alpha = db.fadeDeadIcons or 1.0
661+
alpha = (db.fadeDeadIcons or 1.0) * (db.leaderIconAlpha or 1.0)
662662
end
663-
663+
664664
if db.oorEnabled then
665665
local oorAlpha = db.oorIconsAlpha or 0.5
666666
ApplyOORAlpha(frame.leaderIcon, inRange, alpha, oorAlpha)
@@ -681,11 +681,11 @@ function DF:UpdateRaidTargetIconAppearance(frame)
681681
local deadOrOffline = IsDeadOrOffline(frame)
682682
local inRange = GetInRange(frame)
683683

684-
local alpha = 1.0
684+
local alpha = db.raidTargetIconAlpha or 1.0
685685
if deadOrOffline and db.fadeDeadFrames then
686-
alpha = db.fadeDeadIcons or 1.0
686+
alpha = (db.fadeDeadIcons or 1.0) * (db.raidTargetIconAlpha or 1.0)
687687
end
688-
688+
689689
if db.oorEnabled then
690690
local oorAlpha = db.oorIconsAlpha or 0.5
691691
ApplyOORAlpha(frame.raidTargetIcon, inRange, alpha, oorAlpha)
@@ -706,11 +706,11 @@ function DF:UpdateReadyCheckIconAppearance(frame)
706706
local deadOrOffline = IsDeadOrOffline(frame)
707707
local inRange = GetInRange(frame)
708708

709-
local alpha = 1.0
709+
local alpha = db.readyCheckIconAlpha or 1.0
710710
if deadOrOffline and db.fadeDeadFrames then
711-
alpha = db.fadeDeadIcons or 1.0
711+
alpha = (db.fadeDeadIcons or 1.0) * (db.readyCheckIconAlpha or 1.0)
712712
end
713-
713+
714714
if db.oorEnabled then
715715
local oorAlpha = db.oorIconsAlpha or 0.5
716716
ApplyOORAlpha(frame.readyCheckIcon, inRange, alpha, oorAlpha)

Frames/Headers.lua

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7592,7 +7592,17 @@ function DF:ProcessRosterUpdate()
75927592
if raidDb.petEnabled and DF.UpdateAllRaidPetFrames then
75937593
DF:UpdateAllRaidPetFrames()
75947594
end
7595-
7595+
7596+
-- Refresh summon icons on all frames — clears stale "Summon Pending" icons
7597+
-- when leaving a group or entering an instance (M+ start, zone change)
7598+
if DF.UpdateSummonIcon and DF.IterateAllFrames then
7599+
DF:IterateAllFrames(function(frame)
7600+
if frame and frame.unit then
7601+
DF:UpdateSummonIcon(frame)
7602+
end
7603+
end)
7604+
end
7605+
75967606
if DF.debugHeaders then
75977607
print("|cFF00FF00[DF Headers]|r Roster update processed")
75987608
end

Frames/Update.lua

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -591,6 +591,15 @@ function DF:UpdateUnitFrame(frame, source)
591591
end
592592
if frame.nameText then
593593
local name = DF:GetUnitName(unit) or unit
594+
-- Truncate name if needed (UTF-8 aware)
595+
local nameLength = db.nameTextLength or 0
596+
if nameLength > 0 and DF:UTF8Len(name) > nameLength then
597+
if db.nameTextTruncateMode == "ELLIPSIS" then
598+
name = DF:UTF8Sub(name, 1, nameLength) .. "..."
599+
else
600+
name = DF:UTF8Sub(name, 1, nameLength)
601+
end
602+
end
594603
frame.nameText:SetText(name)
595604
-- TODO CLEANUP: Color now handled by ElementAppearance via ApplyDeadFade
596605
-- frame.nameText:SetTextColor(0.5, 0.5, 0.5, 1)

0 commit comments

Comments
 (0)