m (More efficient) |
Meorawr31439 (talk | contribs) (Mark as removed in 10.0.2) Tag: WoW API docs |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
− | {{ |
+ | {{widgethandler}} |
− | |||
Invoked when an item's information is added to a tooltip. |
Invoked when an item's information is added to a tooltip. |
||
− | == |
+ | ==Arguments== |
− | |||
:;arg1: Tooltip - The Tooltip object to which an item was added. |
:;arg1: Tooltip - The Tooltip object to which an item was added. |
||
− | == |
+ | ==Example== |
− | |||
-- overload the base function for ItemRefTooltip with a custom routine |
-- overload the base function for ItemRefTooltip with a custom routine |
||
ItemRefTooltip:HookScript("OnTooltipSetItem", function(tooltip, ...) |
ItemRefTooltip:HookScript("OnTooltipSetItem", function(tooltip, ...) |
||
Line 20: | Line 17: | ||
tooltip:Show() |
tooltip:Show() |
||
end) |
end) |
||
− | |||
== Details == |
== Details == |
||
− | : This function was added in WoW 2.0.3 |
||
: This gets called twice for Recipes which contain embedded items |
: This gets called twice for Recipes which contain embedded items |
||
+ | |||
+ | ==Patch changes== |
||
+ | {{Patch 10.0.2|note=Removed.}} |
||
+ | {{Patch 2.0.3|note=Added.}} |
Latest revision as of 01:15, 20 October 2022
The API is no longer being updated here until further notice. |
Invoked when an item's information is added to a tooltip.
Arguments
- arg1
- Tooltip - The Tooltip object to which an item was added.
Example
-- overload the base function for ItemRefTooltip with a custom routine ItemRefTooltip:HookScript("OnTooltipSetItem", function(tooltip, ...) local name, link = tooltip:GetItem() local texture = select(10, GetItemInfo(link)) --Add the name and path of the item's texture tooltip:AddLine(texture) --Show the texture graphic on the previous line tooltip:AddTexture(texture) --Repaint tooltip with newly added lines tooltip:Show() end)
Details
- This gets called twice for Recipes which contain embedded items
Patch changes
Patch 10.0.2 (2022-11-15): Removed.
Patch 2.0.3 (2007-01-09): Added.