mirror of
https://github.com/brues-code/pfUI.git
synced 2026-10-20 19:30:49 +00:00
tooltip: add global variable for dodge frames
This commit is contained in:
+12
-10
@@ -83,6 +83,14 @@ pfUI:RegisterModule("tooltip", "vanilla:tbc", function ()
|
|||||||
return pfUI.tooltip.unit
|
return pfUI.tooltip.unit
|
||||||
end
|
end
|
||||||
|
|
||||||
|
pfUI.tooltip.dodge = {
|
||||||
|
"pfPanelRight", "pfChatRight"
|
||||||
|
}
|
||||||
|
|
||||||
|
if C.appearance.bags.movable == "0" then
|
||||||
|
table.insert(pfUI.tooltip.dodge, "pfBag")
|
||||||
|
end
|
||||||
|
|
||||||
pfUI.tooltip:SetAllPoints()
|
pfUI.tooltip:SetAllPoints()
|
||||||
pfUI.tooltip:SetScript("OnShow", function()
|
pfUI.tooltip:SetScript("OnShow", function()
|
||||||
pfUI.tooltip:Update()
|
pfUI.tooltip:Update()
|
||||||
@@ -97,16 +105,10 @@ pfUI:RegisterModule("tooltip", "vanilla:tbc", function ()
|
|||||||
elseif C.tooltip.position == "chat" then
|
elseif C.tooltip.position == "chat" then
|
||||||
local anchor = nil
|
local anchor = nil
|
||||||
|
|
||||||
if pfUI.panel and pfUI.panel.right:IsShown() then
|
for _, frame in pairs(pfUI.tooltip.dodge) do
|
||||||
anchor = pfUI.panel.right
|
if _G[frame] and _G[frame]:IsShown() then
|
||||||
end
|
anchor = _G[frame]
|
||||||
|
end
|
||||||
if pfUI.chat and pfUI.chat.right:IsShown() then
|
|
||||||
anchor = pfUI.chat.right
|
|
||||||
end
|
|
||||||
|
|
||||||
if pfUI.bag and pfUI.bag.right and pfUI.bag.right:IsShown() and C.appearance.bags.movable == "0" then
|
|
||||||
anchor = pfUI.bag.right
|
|
||||||
end
|
end
|
||||||
|
|
||||||
if anchor then
|
if anchor then
|
||||||
|
|||||||
Reference in New Issue
Block a user