end |
|
function MultiScreenSupport:setParentAnchor(frame) |
local hookFunction = function(frame) |
local point, relativeTo, relativePoint, xOfs, yOfs = frame:GetPoint() |
if relativeTo == nil or relativeTo:GetName() == UIParent:GetName() then |
if not InCombatLockdown() then |
frame:ClearAllPoints() |
frame:SetPoint(point, MultiScreenSupportParent, relativePoint, xOfs, yOfs) |
end |
end |
end |
local point, relativeTo, relativePoint, xOfs, yOfs = frame:GetPoint() |
if relativeTo == nil or relativeTo:GetName() == UIParent:GetName() then |
frame:HookScript("OnUpdate", function(self) |
local point, relativeTo, relativePoint, xOfs, yOfs = self:GetPoint() |
if relativeTo == nil or relativeTo:GetName() == UIParent:GetName() then |
self:ClearAllPoints() |
self:SetPoint(point, MultiScreenSupportParent, relativePoint, xOfs, yOfs) |
end |
end) |
if frame:GetName() == "OrderHallTalentFrame" then--NEEDED since 7.2.5 probably because of chromie |
frame:HookScript("OnShow", function(self) |
frame:HookScript("OnUpdate", hookFunction) |
end) |
else |
frame:HookScript("OnUpdate", hookFunction) |
end |
end |
end |
|