User Guide

478 Chapter 2: ActionScript Language Reference
Mouse.hide()
Availability
Flash Player 5.
Usage
Mouse.hide() : Boolean
Parameters
None.
Returns
A Boolean value: true if the pointer is visible; false otherwise.
Description
Method; hides the pointer in a SWF file. The pointer is visible by default.
Example:
The following code hides the standard mouse pointer, and sets the x and y positions of the
cursor_mc movie clip instance to the x and y cursor position. Create a movie clip and set its
Linkage identifier to
cursor_id. Add the following ActionScript to Frame 1 of the Timeline:
// to use this script you need a symbol
// in your library with a Linkage Identifier of "pointer_id".
this.attachMovie("pointer_id", "pointer_mc", this.getNextHighestDepth());
Mouse.hide();
var mouseListener:Object = new Object();
mouseListener.onMouseMove = function() {
pointer_mc._x = _xmouse;
pointer_mc._y = _ymouse;
updateAfterEvent();
};
Mouse.addListener(mouseListener);
See also
Mouse.show(), MovieClip._xmouse, MovieClip._ymouse