So I found this older post giving an example of how to drag a spell/item to a frame. However, when I try this is doesn't work.
https://www.wowinterface.com/forums/...ad.php?t=57561
Lua Code:
if(testframe == nil) then --This is built in an in game editor, using check for nil so I don't create multiple frames.
testframe = CreateFrame("Frame", "aframe", UIParent, "ButtonFrameTemplate")
ButtonFrameTemplate_HidePortrait(testframe)
ButtonFrameTemplate_HideButtonBar(testframe)
testframe:SetTitle("Drop")
testframe:SetSize(100,100)
testframe:SetPoint("LEFT", 100, 0)
end
testframe:SetScript("OnMouseUp", function (self, button)
print(GetCursorInfo())
end)
So what does happen is I grab an item and drag it to the frame while still holding the mouse down. When I release, nothing happens. If I then click and release with the item still on my mouse pointer, it then fires the onmouseup script. How would I register the mouseup when the mousedown didn't happen on that frame?