From 30aad8b492f2d6868f7220391e88c07ce974620f Mon Sep 17 00:00:00 2001 From: Road-block Date: Wed, 13 Feb 2019 13:48:56 +0200 Subject: [PATCH] libtipscan: fix scanning tooltip breaking due to show/hide of itself or uiparent --- libs/libtipscan.lua | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/libs/libtipscan.lua b/libs/libtipscan.lua index e50f1698..72d11a9b 100644 --- a/libs/libtipscan.lua +++ b/libs/libtipscan.lua @@ -125,9 +125,9 @@ end libtipscan._registry = setmetatable({},{__index = function(t,k) local v = CreateFrame("GameTooltip", string.format("%s%s",baseName,k), nil, "GameTooltipTemplate") - v:SetOwner(UIParent,"ANCHOR_NONE") + v:SetOwner(v,"ANCHOR_NONE") v:SetScript("OnHide", function () - this:SetOwner(UIParent,"ANCHOR_NONE") + this:SetOwner(this,"ANCHOR_NONE") end) function v:Text() return getText(self) @@ -145,9 +145,6 @@ libtipscan._registry = setmetatable({},{__index = function(t,k) local method = method local old = v[method] v[method] = function(v, a1,a2,a3,a4,a5,a6,a7,a8,a9,a10) - if v:IsShown() then - v:Hide() - end v:ClearLines() return old(v, a1,a2,a3,a4,a5,a6,a7,a8,a9,a10) end