From ca67aa012c2d81e5776793310bd4d57100811318 Mon Sep 17 00:00:00 2001 From: shagu Date: Sun, 1 Oct 2017 23:45:06 +0200 Subject: [PATCH] map: don't close other windows for worldmap --- modules/map.lua | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/modules/map.lua b/modules/map.lua index 44aaac94..f06ced33 100644 --- a/modules/map.lua +++ b/modules/map.lua @@ -1,4 +1,14 @@ pfUI:RegisterModule("map", function () + + function _G.ToggleWorldMap() + if WorldMapFrame:IsShown() then + WorldMapFrame:Hide() + else + WorldMapFrame:Show() + table.insert(UISpecialFrames, "WorldMapFrame") + end + end + local pfMapLoader = CreateFrame("Frame", nil, UIParent) pfMapLoader:RegisterEvent("PLAYER_ENTERING_WORLD") pfMapLoader:SetScript("OnEvent", function() @@ -61,4 +71,4 @@ pfUI:RegisterModule("map", function () end end) end) -end) \ No newline at end of file +end)