![MACROMEDIA Flash Lite 2 Скачать руководство пользователя страница 511](http://html1.mh-extra.com/html/macromedia/flash-lite-2/flash-lite-2_reference_687553511.webp)
MovieClip
511
Example
The following example creates a
triangle
movie clip instance dynamically. When you run
the SWF file, click the movie clip to rotate it:
this.createEmptyMovieClip("triangle", this.getNextHighestDepth());
triangle.beginFill(0x0000FF, 100);
triangle.moveTo(100, 100);
triangle.lineTo(100, 150);
triangle.lineTo(150, 100);
triangle.lineTo(100, 100);
triangle.onMouseUp= function() {
this._ro= 15;
};
See also
_rotation (Button._rotation property)
,
_rotation (TextField._rotation
property)
setMask (MovieClip.setMask method)
public setMask(mc:
Object
) : Void
Makes the movie clip in the parameter
mc
a mask that reveals the calling movie clip.
The
setMask()
method allows multiple-frame movie clips with complex, multilayered
content to act as masks (which is possible by using mask layers). If you have device fonts in a
masked movie clip, they are drawn but not masked. You can't set a movie clip to be its own
mask, for example,
my_mc.setMask(my_mc)
.
If you create a mask layer that contains a movie clip, and then apply the
setMask()
method
to it, the
setMask()
call takes priority and this is not reversible. For example, you could have
a movie clip in a mask layer called
UIMask
that masks another layer that contains another
movie clip called
UIMaskee
. If, as the SWF file plays, you call
UIMask.setMask(UIMaskee)
,
from that point on,
UIMask
is masked by
UIMaskee
.
To cancel a mask created with ActionScript, pass the value
null
to the
setMask()
method.
The following code cancels the mask without affecting the mask layer in the Timeline.
UIMask.setMask(null);
You can extend the methods and event handlers of the MovieClip class by creating a subclass.
Availability:
ActionScript 1.0; Flash Lite 2.0
Содержание Flash Lite 2
Страница 1: ...Flash Lite 2 x ActionScript Language Reference...
Страница 22: ...22 Contents...
Страница 244: ...244 ActionScript language elements...
Страница 760: ...760 ActionScript classes...