Calls to C_Ping.GetTargetWorldPing without the Ping UI addon being loaded can break the ability to open the radial wheel when dragging on the game world.
Test case
Log in and run the following command: /run C_Ping.GetTargetWorldPing(0, 0)
Hold the ping hotkey and drag on the world frame to open the ping wheel.
On step 2, the ping wheel won't open - you'll just get a red UI error message saying "Can't ping this.".
Explanation
Direct calls to C_Ping.GetTargetWorldPing trigger the ping radial frame to be created and the corresponding PING_RADIAL_WHEEL_FRAME_CREATED event to fire.
This event isn't handled by UIParent, so if the Blizzard_PingUI addon hasn't been loaded when this event fires then that addon will never receive it, and the radialParent field is never initialized to a non-nil value. This leads to the "Can't ping this" message (PING_ERROR) being displayed when attempting to open the wheel.
Solution
Either handle the PING_RADIAL_WHEEL_FRAME_CREATED event in UIParent and make it load the ping UI (and forward the event on), or make C_Ping.CreateFrame return the created frame and assign the result to self.radialParent inside the OnLoad handler of PingFrame.
Calls to C_Ping.GetTargetWorldPing without the Ping UI addon being loaded can break the ability to open the radial wheel when dragging on the game world.
Test case
/run C_Ping.GetTargetWorldPing(0, 0)
On step 2, the ping wheel won't open - you'll just get a red UI error message saying "Can't ping this.".
Explanation
Direct calls to C_Ping.GetTargetWorldPing trigger the ping radial frame to be created and the corresponding
PING_RADIAL_WHEEL_FRAME_CREATED
event to fire.This event isn't handled by UIParent, so if the Blizzard_PingUI addon hasn't been loaded when this event fires then that addon will never receive it, and the
radialParent
field is never initialized to a non-nil value. This leads to the "Can't ping this" message (PING_ERROR
) being displayed when attempting to open the wheel.Solution
Either handle the
PING_RADIAL_WHEEL_FRAME_CREATED
event in UIParent and make it load the ping UI (and forward the event on), or make C_Ping.CreateFrame return the created frame and assign the result toself.radialParent
inside the OnLoad handler of PingFrame.