View Single Post
Old 06-14-2009, 08:37 PM   #2
Neffi
A Defias Bandit
Interface Author - Click to view interfaces
Join Date: Jun 2009
Posts: 3
You can use the following code to make any frame movable:

Quote:
/run local f=framename; f:SetMovable(true); f:EnableMouse(true); f:SetUserPlaced(true); f:SetScript("OnMouseDown", f.StartMoving); f:SetScript("OnMouseUp", f.StopMovingOrSizing);
You'll need to replace framename with the frame's global name. You can get that with:

Quote:
/run print( GetMouseFocus():GetName() )
Which will print it into the chat.

This doesn't work on all frames, but should work on almost all the default UI's frames. I know for a fact it works on the basic unit frames.

(This will automatically save between each game session. Reload or relog to lock the frames into their new places.)

Last edited by Neffi : 06-15-2009 at 04:18 AM.
Neffi is offline   Reply With Quote