From c8e4068fa652c88e892c48734e35e0d504c6f745 Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Tue, 16 Sep 2008 15:42:39 +0200 Subject: [PATCH] Applyed workaround for the Action Blocked message when using /click macros Apparently the cache for the click-frames taints its first element after frame creation, so a one-time call of GetClickFrame() after frame-creation removes that tainted element from the cache, and all future calls return the proper secure frame. [1] [1]: http://forums.worldofwarcraft.com/thread.html?topicId=3773503744&sid=1&pageNo=4#60 --- buttonPrototypes/ActionButton.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/buttonPrototypes/ActionButton.lua b/buttonPrototypes/ActionButton.lua index 7cb42bc..6dae463 100644 --- a/buttonPrototypes/ActionButton.lua +++ b/buttonPrototypes/ActionButton.lua @@ -24,6 +24,9 @@ function Bartender4.Button:Create(id, parent) local absid = (parent.id - 1) * 12 + id local name = ("BT4Button%d"):format(absid) local button = setmetatable(CreateFrame("CheckButton", name.."Secure", parent, "SecureActionButtonTemplate"), Button_MT) + -- work around for "blocked" message when using /click macros + GetClickFrame(name .. "Secure") + button.rid = id button.id = absid button.parent = parent