This addon will add a new widget to the TidyPlatesWidgets table:
TidyPlatesWidgets.CreateTotemWidget
To properly reference this widget to incorporate into your theme, you'll need to make a function to be used in your theme's OnUpdate.
-- Example OnUpdate --
local function OnUpdate(plate, unit)
if not plate.widgets.TotemIconWidget then
plate.widgets.TotemIconWidget = TidyPlatesWidgets.CreateTotemWidget(plate)
plate.widgets.TotemIconWidget:SetPoint("CENTER", plate, "TOP", 0, -4) -- Placement ( reference, frame, alignment, x , y )
plate.widgets.TotemIconWidget:SetHeight(22) -- Adjust the Height
plate.widgets.TotemIconWidget:SetWidth(22) -- Adjust the Width
end
plate.widgets.TotemIconWidget:Update(unit)
end
TidyPlatesThemeList.OnUpdate = OnUpdate
End
-- Example OnUpdate --
You will also need to make sure your theme's options allow the usage of OnUpdate:
TidyPlatesThemeList.options.useOnUpdate = true
...or for multi style themes:
TidyPlatesThemeList.options.useOnUpdate = true
It is also wise to change your theme's ToC file to add this addon as a dependancy:
## RequiredDeps: TidyPlates, TidyPlates_TotemWidget
If you're unsure as to how to create your own theme, please reference the TDK ( Theme Development Kit ) available here:
http://www.wowinterface.com/downloads/info14267.html |
|