Preserve minimap tracking show handler
This commit is contained in:
+22
-17
@@ -1,17 +1,22 @@
|
|||||||
local _G = ShaguTweaks.GetGlobalEnv()
|
local T = ShaguTweaks.T
|
||||||
local T = ShaguTweaks.T
|
local hooksecurefunc = hooksecurefunc or ShaguTweaks.hooksecurefunc
|
||||||
|
|
||||||
local module = ShaguTweaks:register({
|
local module = ShaguTweaks:register({
|
||||||
title = T["Hide Tracking Icon"],
|
title = T["Hide Tracking Icon"],
|
||||||
description = T["Hides the tracking icon from the minimap."],
|
description = T["Hides the tracking icon from the minimap."],
|
||||||
expansions = { ["vanilla"] = true },
|
expansions = { ["vanilla"] = true },
|
||||||
category = T["World & MiniMap"],
|
category = T["World & MiniMap"],
|
||||||
enabled = true,
|
enabled = true,
|
||||||
order = 74,
|
order = 74,
|
||||||
})
|
})
|
||||||
|
|
||||||
module.enable = function(self)
|
module.enable = function(self)
|
||||||
-- Désactive l'affichage automatique du bouton de suivi
|
-- Keep the tracking icon hidden without replacing its Show method. This
|
||||||
MiniMapTrackingFrame.Show = function() end
|
-- preserves Blizzard/Turtle and addon behavior while applying our visual
|
||||||
MiniMapTrackingFrame:Hide()
|
-- preference after every attempted show.
|
||||||
end
|
hooksecurefunc(MiniMapTrackingFrame, "Show", function()
|
||||||
|
MiniMapTrackingFrame:Hide()
|
||||||
|
end)
|
||||||
|
|
||||||
|
MiniMapTrackingFrame:Hide()
|
||||||
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user