Fix tooltip: hide on dropdown open, conditional cancel hint

This commit is contained in:
MarcelineVQ
2026-03-07 17:28:17 -08:00
parent 528df27780
commit 44f13c42f4
+5 -2
View File
@@ -199,6 +199,7 @@ end)
-- Left-click opens dropdown, right-click cancels tracking (native behavior)
MiniMapTrackingFrame:SetScript("OnMouseUp", function()
if arg1 == "LeftButton" then
GameTooltip:Hide()
scanSpellbook()
ToggleDropDownMenu(1, nil, dropdown, MiniMapTrackingFrame, 0, 0)
elseif arg1 == "RightButton" then
@@ -206,7 +207,7 @@ MiniMapTrackingFrame:SetScript("OnMouseUp", function()
end
end)
-- Keep native tooltip but add hint text
-- Tooltip
MiniMapTrackingFrame:SetScript("OnEnter", function()
GameTooltip:SetOwner(this, "ANCHOR_BOTTOMLEFT")
GameTooltip:SetTrackingSpell()
@@ -214,7 +215,9 @@ MiniMapTrackingFrame:SetScript("OnEnter", function()
GameTooltip:AddLine("Tracking")
end
GameTooltip:AddLine("Click to select tracking", 0.5, 0.5, 0.5)
GameTooltip:AddLine("Right-click to cancel", 0.5, 0.5, 0.5)
if GetTrackingTexture() then
GameTooltip:AddLine("Right-click to cancel", 0.5, 0.5, 0.5)
end
GameTooltip:Show()
end)