Example
The following code, attached to a movie clip on the main Timeline, hides the standard pointer,
and sets the x and y positions of the
positions in the main Timeline.
onClipEvent(enterFrame){
Mouse.hide();
customPointer_mc._x = _root._xmouse;
customPointer_mc._y = _root._ymouse;
}
See also
,
Mouse.show()
Mouse.onMouseDown
Availability
Flash Player 6.
Usage
someListener.onMouseDown
Parameters
None.
Returns
Nothing.
Description
Listener; notified when the mouse is pressed. To use the
listener object. You can then define a function for
register the listener with the Mouse object, as in the following code:
someListener = new Object();
someListener.onMouseDown = function () { ... };
Mouse.addListener(someListener);
Listeners enable different pieces of code to cooperate because multiple listeners can receive
notification about a single event.
See also
Mouse.addListener()
478
Chapter 12: ActionScript Dictionary
customPointer_mc
,
MovieClip._xmouse
movie clip instance to the x and y mouse
MovieClip._ymouse
onMouseDown
onMouseDown
listener, you must create a
and use
addListener()
to
Need help?
Do you have a question about the FLASH MX 2004 - ACTIONSCRIPT and is the answer not in the manual?
Questions and answers