You recognize a greater performance benefit with a movie clip that would have many
transparent regions if
were not set.
opaqueBackground
Note:The opaque background region is not matched in a
method that has the
hitTest()
parameter set to
.
shapeFlag
true
Availability: ActionScript 1.0; Flash Player 8
Example
The following example creates a triangle outline and sets the
property to
opaqueBackground
a specific color:
var triangle:MovieClip = this.createEmptyMovieClip("triangle",
this.getNextHighestDepth());
triangle._x = triangle._y = 50;
triangle.lineStyle(3, 0xFFCC00);
triangle.lineTo(0, 30);
triangle.lineTo(50, 0);
triangle.lineTo(0, 0);
triangle.endFill();
triangle.opaqueBackground = 0xCCCCCC;
If your SWF file includes a version 2 component, use the version 2 components
DepthManager class instead of the
method, which is
MovieClip.getNextHighestDepth()
used in this example.
See also
,
cacheAsBitmap (MovieClip.cacheAsBitmap property)
hitTest (MovieClip.hitTest
method)
_parent (MovieClip._parent property)
public _parent : MovieClip
A reference to the movie clip or object that contains the current movie clip or object. The
current object is the object that references the
property. Use the
property to
_parent
_parent
specify a relative path to movie clips or objects that are above the current movie clip or object.
You can use
to move up multiple levels in the display list, as in the following code:
_parent
this._parent._parent._alpha = 20;
Availability: ActionScript 1.0; Flash Player 5
912
ActionScript classes
Need help?
Do you have a question about the FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE and is the answer not in the manual?