Automated updating of API pages at this location, to reflect patch changes, has ceased from 10.1.7 onwards. |
Returns updated UI widget information.
UPDATE_UI_WIDGET: widgetInfo
Payload[]
- widgetInfo
- UIWidgetInfo
Field | Type | Description |
---|---|---|
widgetID | number | UiWidget.db2 |
widgetSetID | number | UiWidgetSetID |
widgetType | Enum.UIWidgetVisualizationType | |
unitToken | string? | UnitId; Added in 9.0.1 |
Example[]
Prints UI widget information when UPDATE_UI_WIDGET fires.
local function OnEvent(self, event, w)
local typeInfo = UIWidgetManager:GetWidgetTypeInfo(w.widgetType)
local visInfo = typeInfo.visInfoDataFunction(w.widgetID)
print(w.widgetSetID, w.widgetType, w.widgetID, visInfo)
end
local f = CreateFrame("Frame")
f:RegisterEvent("UPDATE_UI_WIDGET")
f:SetScript("OnEvent", OnEvent)
You can query the information from the specific data function yourself, or use visInfo
which does it programmatically.
E.g. for the Arathi Basin PvP objective:
- Widget Set ID:
1
- Top center part of the screen - Widget Type:
3
- Enum.UIWidgetVisualizationType.DoubleStatusBar - Widget ID:
1671
- UiWidget.VisID -> UiWidgetVisualization.ID 1200 "PvP - Domination - Double Status Bar"
/dump C_UIWidgetManager.GetDoubleStatusBarWidgetVisualizationInfo(1671)
Patch changes[]
Patch 8.0.1 (2018-07-17): Added.