itemLinks in an addon frame?
Hi. I've been trying to find out if it's possible to have clickable itemLinks on a frame I've created myself? I feel like I can't find any information on this and tweaking things myself has gotten me nowhere. Is this only available in the default chat frames?
For example: Code:
local frame = CreateFrame("Frame", "testFrame", UIParent, "BasicFrameTemplate") |
You have to tell your frame what to do when a hyperlink is interacted with by setting the relevant scripts for OnHyperlinkClick, OnHyperlinkEnter, and/or OnHyperlinkLeave. If you want hyperlinks to act like the default chat frames then all you need to do is add:
Code:
frame:SetScript("OnHyperlinkClick", ChatFrame_OnHyperlinkShow) |
Thank you! Shame I spent so much time banging my head on such a simple issue. lol
|
All times are GMT -6. The time now is 10:30 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI