Contents
Articles
Behaviors
Books
Director News
Director Web Sites
FAQ
Games
Mailing Lists
News Groups
Project Examples
Reviews
Software
Tools
Useful Web Sites
Utilities
Xtras

Don't miss these
Drag around-Alphamania
Page turn
simODBC Xtra
password field
Set DirectToStage Property of a Flash Member
myWindow
Made with Macromedia and Shockwave Licensing Programs
MediaPlayer Xtra
Trigonometry Class v0.6
Frame Trigger-Alphamania
 

 

 

Behavior Use any sprite as a dragger

Added on 7/2/2003

 

Compatibilities:

This item has not yet been rated

Author: troyhipolito (website)

This time we will see how to make a behavior to use any sprite as a dragger, so while you maintain pressed this sprite the window will be relocated according to the position of the mouse. The window could be the stage or a MIAW. for a full tutorial see: http://www.shocksites.com/openSource/041203.asp

on mouseDown me
repeat while the mouseDown
A = the activeWindow.rect
N = the mouseLoc - the clickLoc
(the activeWindow).rect = rect(A[1]+N[1], A[2]+N[2], A[3]+N[1], A[4]+N[2])
end repeat
end

 


Contact

MMI
36 South Court Sq
Suite 300
Newnan, GA 30263
USA

Send e-mail