@@ -7,16 +7,14 @@ local frame = CreateFrame("Frame", name)
77local bmTooltip = CreateFrame (" GameTooltip" , " BasicMinimapTooltip" , UIParent , " GameTooltipTemplate" )
88frame :Hide ()
99
10- local TrackingButton = MiniMapTrackingButton
11-
1210local blizzButtonNicknames = {
1311 zoomIn = MinimapZoomIn ,
1412 zoomOut = MinimapZoomOut ,
1513 difficulty = MiniMapInstanceDifficulty ,
1614 calendar = GameTimeFrame ,
1715 mail = MiniMapMailFrame ,
1816 pvp = MiniMapBattlefieldFrame ,
19- lfg = MiniMapLFGFrame ,
17+ -- lfg = LFGMinimapFrame, -- loads on PLAYER_ENTERING_WORLD
2018}
2119frame .blizzButtonNicknames = blizzButtonNicknames
2220
@@ -637,17 +635,17 @@ local function Login(self)
637635 self .SetParent (MiniMapWorldMapButton , self )
638636
639637 -- Tracking button
640- if not TrackingButton or not TrackingButton .SetMenuAnchor then -- Wrath
638+ if not MiniMapTrackingButton or not MiniMapTrackingButton .SetMenuAnchor then -- Wrath
641639 self .SetParent (MiniMapTracking , self )
642640 else -- Cata
643641 self .SetParent (MiniMapTracking , self )
644- self .SetParent (TrackingButton , Minimap )
645- self .ClearAllPoints (TrackingButton )
646- self .SetPoint (TrackingButton , " CENTER" )
647- self .SetFixedFrameStrata (TrackingButton , false )
648- self .SetFrameStrata (TrackingButton , " BACKGROUND" )
649- self .SetFixedFrameStrata (TrackingButton , true )
650- TrackingButton :SetMenuAnchor (AnchorUtil .CreateAnchor (" CENTER" , Minimap , " CENTER" ))
642+ self .SetParent (MiniMapTrackingButton , Minimap )
643+ self .ClearAllPoints (MiniMapTrackingButton )
644+ self .SetPoint (MiniMapTrackingButton , " CENTER" )
645+ self .SetFixedFrameStrata (MiniMapTrackingButton , false )
646+ self .SetFrameStrata (MiniMapTrackingButton , " BACKGROUND" )
647+ self .SetFixedFrameStrata (MiniMapTrackingButton , true )
648+ MiniMapTrackingButton :SetMenuAnchor (AnchorUtil .CreateAnchor (" CENTER" , Minimap , " CENTER" ))
651649 end
652650
653651 -- Classic Wrath
@@ -691,7 +689,6 @@ local function Login(self)
691689 -- PvE/PvP Queue button
692690 -- self.SetParent(QueueStatusMinimapButton, Minimap)
693691 self .SetParent (MiniMapBattlefieldFrame , Minimap ) -- QueueStatusMinimapButton (Retail) > MiniMapBattlefieldFrame (Classic)
694- self .SetParent (MiniMapLFGFrame , Minimap ) -- Special LFG button for classic/TBC
695692
696693 -- Update all blizz button positions
697694 for nickName , button in next , blizzButtonNicknames do
@@ -748,11 +745,7 @@ local function Login(self)
748745 GameTimeFrame :Click ()
749746 end
750747 elseif btn == frame .db .profile .trackingBtn then
751- if TrackingButton and TrackingButton .OpenMenu then -- Cata
752- TrackingButton :OpenMenu ()
753- else -- Wrath
754- ToggleDropDownMenu (1 , nil , MiniMapTrackingDropDown , minimapFrame )
755- end
748+ MiniMapTrackingButton :OpenMenu ()
756749 -- elseif btn == frame.db.profile.missionsBtn then
757750 -- GarrisonLandingPageMinimapButton:Click()
758751 elseif btn == frame .db .profile .mapBtn then
@@ -811,6 +804,12 @@ function frame:LOADING_SCREEN_DISABLED(event)
811804 CreateCoords (self )
812805 local fullMinimapSize = self .db .profile .size + self .db .profile .borderSize
813806 CreateZoneText (self , fullMinimapSize )
807+ if LFGMinimapFrame then -- Classic era, TBC, wrath only, loads after PLAYER_ENTERING_WORLD
808+ blizzButtonNicknames .lfg = LFGMinimapFrame
809+ self .SetParent (LFGMinimapFrame , Minimap ) -- Special LFG button for classic era
810+ self .ClearAllPoints (LFGMinimapFrame )
811+ ldbi :SetButtonToPosition (LFGMinimapFrame , self .db .profile .blizzButtonLocation .lfg )
812+ end
814813end
815814frame :RegisterEvent (" LOADING_SCREEN_DISABLED" )
816815
0 commit comments