Version: 9.1.6 (also reproduced on 8.9.8). Retail 12.1.0 and the 12.1.5 PTR.
Summary: A third-party minimap button collected into the Minimap button bag stays at alpha 0 (blank slot, tooltip still works) after its addon calls Show() on it while the bag is closed. The alpha is never restored on later opens.
Reproduction
Any addon whose minimap button uses LibDBIcon-1.0 works. I used DelveGuide (LibDBIcon10_DelveGuide), but the addon does not matter.
- Log in with the Minimap module and its button bag enabled. Open the bag: the addon's icon is in its slot.
- Close the bag. Make the addon hide and re-show its button, for example by toggling its "show minimap button" setting off and on, or:
/run local l=LibStub("LibDBIcon-1.0") l:Hide("DelveGuide") l:Show("DelveGuide")
- Open the bag. The slot is still there but empty. Hovering the empty slot shows the addon's tooltip.
State of the button at that point:
/run print(LibDBIcon10_DelveGuide:GetAlpha()) prints 0
- Its parent is the flyout panel, it is shown, its icon texture is set and shown at 18x18, the parent is shown at alpha 1.
/run LibDBIcon10_DelveGuide:SetAlpha(1) makes it visible again until the next Show() with the bag closed.
The same blank-on-first-open happens at login for buttons whose library creates and shows them at PLAYER_LOGIN, i.e. after the bag has already gathered and hooked them.
Cause (EllesmereUIMinimap/EllesmereUIMinimap.lua, main)
HideMinimapChild (line 1182) installs a Show hook on each collected button. The hook (lines 1205-1213) does self:SetAlpha(0) whenever Show fires while the flyout is not shown. It never checks whether the button is already parented to flyoutPanel, so buttons that were adopted into the bag get zeroed too.
ShowFlyoutPanel (line 648) only calls BuildFlyoutContents when _flyoutBuilt is false (line 665). The btn:SetAlpha(1) that undoes the hook lives inside LayoutFlyoutButtons (line 501), so once the grid has been built, opening the bag never restores alpha. The hook's own comment covers Show() while the bag is open, but not Show() while it is closed.
Suggested fix
Either one is enough on its own.
A. In the Show hook (line 1211). A button already parented to the flyout cannot appear on the minimap, so there is no reason to zero it; the flyout's own Hide() hides it.
if mp and mp.enabled and not flyoutOwnedFrames[self]
and self:GetParent() ~= flyoutPanel then
self:SetAlpha(0)
end
B. In ShowFlyoutPanel, after flyoutPanel:Show(). Re-assert alpha on every open, the same way _EMIN_RefreshFlyout (line 634) already does for profile swaps.
for _, btn in ipairs(cachedAddonButtons) do
if btn:GetParent() == flyoutPanel and _addonVisible[btn] ~= false then
_suppressVisTrack = true
btn:SetAlpha(1); btn:Show()
_suppressVisTrack = false
end
end
A fixes the reported case at the source. B also covers anything else that lowers alpha between opens. Neither touches ungrouped buttons or buttons that were never collected, and neither adds an event, a hook or a timer.
Workaround for users meanwhile: put the addon on the ungrouped-buttons list.
Version: 9.1.6 (also reproduced on 8.9.8). Retail 12.1.0 and the 12.1.5 PTR.
Summary: A third-party minimap button collected into the Minimap button bag stays at alpha 0 (blank slot, tooltip still works) after its addon calls Show() on it while the bag is closed. The alpha is never restored on later opens.
Reproduction
Any addon whose minimap button uses LibDBIcon-1.0 works. I used DelveGuide (
LibDBIcon10_DelveGuide), but the addon does not matter./run local l=LibStub("LibDBIcon-1.0") l:Hide("DelveGuide") l:Show("DelveGuide")State of the button at that point:
/run print(LibDBIcon10_DelveGuide:GetAlpha())prints0/run LibDBIcon10_DelveGuide:SetAlpha(1)makes it visible again until the next Show() with the bag closed.The same blank-on-first-open happens at login for buttons whose library creates and shows them at PLAYER_LOGIN, i.e. after the bag has already gathered and hooked them.
Cause (EllesmereUIMinimap/EllesmereUIMinimap.lua, main)
HideMinimapChild(line 1182) installs a Show hook on each collected button. The hook (lines 1205-1213) doesself:SetAlpha(0)whenever Show fires while the flyout is not shown. It never checks whether the button is already parented toflyoutPanel, so buttons that were adopted into the bag get zeroed too.ShowFlyoutPanel(line 648) only callsBuildFlyoutContentswhen_flyoutBuiltis false (line 665). Thebtn:SetAlpha(1)that undoes the hook lives insideLayoutFlyoutButtons(line 501), so once the grid has been built, opening the bag never restores alpha. The hook's own comment covers Show() while the bag is open, but not Show() while it is closed.Suggested fix
Either one is enough on its own.
A. In the Show hook (line 1211). A button already parented to the flyout cannot appear on the minimap, so there is no reason to zero it; the flyout's own Hide() hides it.
B. In
ShowFlyoutPanel, afterflyoutPanel:Show(). Re-assert alpha on every open, the same way_EMIN_RefreshFlyout(line 634) already does for profile swaps.A fixes the reported case at the source. B also covers anything else that lowers alpha between opens. Neither touches ungrouped buttons or buttons that were never collected, and neither adds an event, a hook or a timer.
Workaround for users meanwhile: put the addon on the ungrouped-buttons list.