mirror of
https://github.com/brues-code/pfUI.git
synced 2026-09-21 23:26:56 +00:00
api: ignore and skip invalid frame anchors
This commit is contained in:
@@ -715,6 +715,7 @@ end
|
||||
-- 'position' [string] where it should appear, takes the following:
|
||||
-- "TOP", "RIGHT", "BOTTOM", "LEFT"
|
||||
function pfUI.api.AlignToPosition(frame, anchor, position, spacing)
|
||||
if frame == anchor then return end
|
||||
frame:ClearAllPoints()
|
||||
if position == "TOP" and anchor then
|
||||
frame:SetPoint("BOTTOMLEFT", anchor, "TOPLEFT", 0, (spacing or 0))
|
||||
|
||||
Reference in New Issue
Block a user