@@ -50,16 +50,16 @@ function BL:UIWidgetTemplateStatusBar()
50
50
end
51
51
end
52
52
53
- function BL :CaptureBar_PVP ()
53
+ function BL :BelowMinimap_CaptureBar ()
54
54
self .LeftLine :SetAlpha (0 )
55
55
self .RightLine :SetAlpha (0 )
56
56
self .BarBackground :SetAlpha (0 )
57
57
self .SparkNeutral :SetAlpha (0 )
58
58
59
+ self .GlowPulseAnim :Stop ()
59
60
self .Glow1 :SetAlpha (0 )
60
61
self .Glow2 :SetAlpha (0 )
61
62
self .Glow3 :SetAlpha (0 )
62
- self .GlowPulseAnim :Stop ()
63
63
64
64
self .LeftBar :SetVertexColor (0.2 , 0.6 , 1.0 )
65
65
self .RightBar :SetVertexColor (0.9 , 0.2 , 0.2 )
@@ -80,43 +80,41 @@ function BL:CaptureBar_PVP()
80
80
end
81
81
end
82
82
83
- function BL :CaptureBar_EmberCourt () end
83
+ function BL :BelowMinimap_EmberCourt () end
84
84
85
85
local captureBarSkins = {
86
- [2 ] = BL .CaptureBar_PVP ,
87
- [252 ] = BL .CaptureBar_EmberCourt
86
+ [2 ] = BL .BelowMinimap_CaptureBar ,
87
+ [252 ] = BL .BelowMinimap_EmberCourt
88
88
}
89
89
90
- function BL :WidgetCaptureBar_Update (_ , container )
90
+ function BL :BelowMinimap_UpdateBar (_ , container )
91
91
if self :IsForbidden () or not container then return end
92
92
93
93
local skinFunc = captureBarSkins [container .widgetSetID ]
94
94
if skinFunc then skinFunc (self ) end
95
95
end
96
96
97
- function BL :WidgetCaptureBar_ProcessWidget (widgetID , widgetType )
97
+ function BL :UIWidgetTemplateCaptureBar (widgetInfo , container )
98
+ if container == _G .UIWidgetBelowMinimapContainerFrame then return end -- handled by ProcessWidget
99
+
100
+ BL .BelowMinimap_UpdateBar (self , widgetInfo , container )
101
+ end
102
+
103
+ function BL :BelowMinimap_ProcessWidget (widgetID )
98
104
if not self or not self .widgetFrames then return end
99
105
100
106
if widgetID then
101
107
local bar = self .widgetFrames [widgetID ]
102
- if bar then
103
- BL .WidgetCaptureBar_Update (bar , nil , self )
108
+ if bar then -- excuse me?
109
+ BL .BelowMinimap_UpdateBar (bar , nil , self )
104
110
end
105
- else
111
+ else -- we reloading?
106
112
for _ , bar in next , self .widgetFrames do
107
- BL .WidgetCaptureBar_Update (bar , nil , self )
113
+ BL .BelowMinimap_UpdateBar (bar , nil , self )
108
114
end
109
115
end
110
116
end
111
117
112
- function BL :WidgetCaptureBar_ApplyEffectToFrame (widgetInfo , widgetContainer , frame )
113
- BL .WidgetCaptureBar_Update (self , widgetInfo , widgetContainer , frame )
114
- end
115
-
116
- function BL :WidgetCaptureBar_Setup (widgetInfo , widgetContainer )
117
- BL .WidgetCaptureBar_Update (self , widgetInfo , widgetContainer )
118
- end
119
-
120
118
local function UpdatePosition (frame , _ , anchor )
121
119
local holder = frame .containerHolder
122
120
if holder and anchor ~= holder then
@@ -169,9 +167,9 @@ function BL:HandleWidgets()
169
167
170
168
-- Credits ShestakUI
171
169
hooksecurefunc (_G .UIWidgetTemplateStatusBarMixin , ' Setup' , BL .UIWidgetTemplateStatusBar )
170
+ hooksecurefunc (_G .UIWidgetTemplateCaptureBarMixin , ' Setup' , BL .UIWidgetTemplateCaptureBar )
172
171
173
- -- hooksecurefunc(_G.UIWidgetTemplateCaptureBarMixin, 'Setup', BL.WidgetCaptureBar_Setup)
174
- -- hooksecurefunc(_G.UIWidgetTemplateCaptureBarMixin, 'ApplyEffectToFrame', BL.WidgetCaptureBar_ApplyEffectToFrame)
175
- hooksecurefunc (_G .UIWidgetBelowMinimapContainerFrame , ' ProcessWidget' , BL .WidgetCaptureBar_ProcessWidget )
176
- BL .WidgetCaptureBar_ProcessWidget (_G .UIWidgetBelowMinimapContainerFrame ) -- finds any pre-existing capture bars
172
+ -- Below Minimap Widgets
173
+ hooksecurefunc (_G .UIWidgetBelowMinimapContainerFrame , ' ProcessWidget' , BL .BelowMinimap_ProcessWidget )
174
+ BL .BelowMinimap_ProcessWidget (_G .UIWidgetBelowMinimapContainerFrame ) -- finds any pre-existing capture bars
177
175
end
0 commit comments