From c07d71a4c36074272b8fab2149dc1f253e2c3487 Mon Sep 17 00:00:00 2001 From: shagu Date: Sat, 2 Mar 2019 16:32:31 +0100 Subject: [PATCH] chat: add chatcopy function call --- modules/chat.lua | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/modules/chat.lua b/modules/chat.lua index da7aa7f2..8843d69b 100644 --- a/modules/chat.lua +++ b/modules/chat.lua @@ -165,12 +165,15 @@ pfUI:RegisterModule("chat", function () end) pfUI.chat.urlcopy.SetItemRef = SetItemRef + pfUI.chat.urlcopy.CopyText = function(text) + pfUI.chat.urlcopy.text:SetText(text) + pfUI.chat.urlcopy:Show() + end function _G.SetItemRef(link, text, button) if (strsub(link, 1, 3) == "url") then if string.len(link) > 4 and string.sub(link,1,4) == "url:" then - pfUI.chat.urlcopy.text:SetText(string.sub(link,5, string.len(link))) - pfUI.chat.urlcopy:Show() + pfUI.chat.urlcopy.CopyText(string.sub(link,5, string.len(link))) end return end