Mercurial > wow > askmrrobot
diff ui/Ui.lua @ 181:5c586ff5fee5 v85
gear ui should now show essence differences
author | yellowfive |
---|---|
date | Fri, 14 Feb 2020 14:53:46 -0800 |
parents | eec8032ba9df |
children |
line wrap: on
line diff
--- a/ui/Ui.lua Thu Feb 13 13:22:13 2020 -0800 +++ b/ui/Ui.lua Fri Feb 14 14:53:46 2020 -0800 @@ -418,6 +418,20 @@ end) end +function Amr:SetEssenceTooltip(obj, essenceLink, anchor, x, y) + obj:SetUserData("ttEssenceLink", essenceLink) + obj:SetCallback("OnEnter", function(widget) + local tooltipLink = widget:GetUserData("ttEssenceLink") + if tooltipLink then + GameTooltip:SetOwner(widget.frame, anchor and anchor or "ANCHOR_CURSOR", x, y) + GameTooltip:SetHyperlink(tooltipLink) + end + end) + obj:SetCallback("OnLeave", function(widget) + GameTooltip:Hide() + end) +end + function Amr:RenderCoverChrome(container, width, height) local border = AceGUI:Create("AmrUiPanel")