@awayjs/scene 0.13.325 → 0.13.327
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc +100 -100
- package/README.md +61 -61
- package/bundle/awayjs-scene.umd.js +2 -2
- package/bundle/awayjs-scene.umd.js.map +1 -1
- package/copyVersionToIndex.js +23 -23
- package/dist/index.d.ts +76 -76
- package/dist/index.js +67 -67
- package/dist/lib/Scene.d.ts +85 -85
- package/dist/lib/Scene.d.ts.map +1 -1
- package/dist/lib/Scene.js +285 -285
- package/dist/lib/Settings.d.ts +15 -16
- package/dist/lib/Settings.d.ts.map +1 -1
- package/dist/lib/Settings.js +56 -60
- package/dist/lib/adapters/IDisplayObjectAdapter.d.ts +13 -13
- package/dist/lib/adapters/IDisplayObjectAdapter.js +1 -1
- package/dist/lib/adapters/IFilter.d.ts +24 -24
- package/dist/lib/adapters/IFilter.js +1 -1
- package/dist/lib/adapters/IMovieClipAdapter.d.ts +15 -15
- package/dist/lib/adapters/IMovieClipAdapter.js +1 -1
- package/dist/lib/adapters/ITextfieldAdapter.d.ts +4 -4
- package/dist/lib/adapters/ITextfieldAdapter.js +1 -1
- package/dist/lib/base/IBitmapDrawable.d.ts +11 -11
- package/dist/lib/base/IBitmapDrawable.js +1 -1
- package/dist/lib/base/IFrameLabel.d.ts +4 -4
- package/dist/lib/base/IFrameLabel.js +1 -1
- package/dist/lib/base/IFrameScript.d.ts +5 -5
- package/dist/lib/base/IFrameScript.js +1 -1
- package/dist/lib/base/MouseButtons.d.ts +26 -26
- package/dist/lib/base/MouseButtons.js +1 -1
- package/dist/lib/base/Timeline.d.ts +147 -147
- package/dist/lib/base/Timeline.js +525 -525
- package/dist/lib/base/TimelineActionType.d.ts +18 -18
- package/dist/lib/base/TimelineActionType.js +1 -1
- package/dist/lib/controllers/ControllerBase.d.ts +14 -14
- package/dist/lib/controllers/ControllerBase.js +60 -60
- package/dist/lib/controllers/FirstPersonController.d.ts +78 -78
- package/dist/lib/controllers/FirstPersonController.js +228 -228
- package/dist/lib/controllers/FollowController.d.ts +12 -12
- package/dist/lib/controllers/FollowController.js +27 -27
- package/dist/lib/controllers/HoverController.d.ts +105 -105
- package/dist/lib/controllers/HoverController.js +302 -302
- package/dist/lib/controllers/LookAtController.d.ts +14 -14
- package/dist/lib/controllers/LookAtController.js +68 -68
- package/dist/lib/controllers/SpringController.d.ts +38 -38
- package/dist/lib/controllers/SpringController.js +59 -59
- package/dist/lib/display/Billboard.d.ts +132 -132
- package/dist/lib/display/Billboard.js +397 -397
- package/dist/lib/display/Camera.d.ts +31 -31
- package/dist/lib/display/Camera.js +72 -72
- package/dist/lib/display/DisplayObject.d.ts +926 -921
- package/dist/lib/display/DisplayObject.d.ts.map +1 -1
- package/dist/lib/display/DisplayObject.js +1603 -1595
- package/dist/lib/display/DisplayObjectContainer.d.ts +325 -325
- package/dist/lib/display/DisplayObjectContainer.js +486 -486
- package/dist/lib/display/LineSegment.d.ts +69 -69
- package/dist/lib/display/LineSegment.js +203 -203
- package/dist/lib/display/LoaderContainer.d.ts +504 -504
- package/dist/lib/display/LoaderContainer.js +603 -603
- package/dist/lib/display/MorphSprite.d.ts +20 -20
- package/dist/lib/display/MorphSprite.js +246 -246
- package/dist/lib/display/MovieClip.d.ts +149 -149
- package/dist/lib/display/MovieClip.js +733 -733
- package/dist/lib/display/SimpleButton.d.ts +158 -158
- package/dist/lib/display/SimpleButton.js +228 -228
- package/dist/lib/display/Skybox.d.ts +144 -144
- package/dist/lib/display/Skybox.js +288 -288
- package/dist/lib/display/Sprite.d.ts +65 -65
- package/dist/lib/display/Sprite.js +134 -134
- package/dist/lib/display/TextField.d.ts +1104 -1104
- package/dist/lib/display/TextField.js +3019 -3019
- package/dist/lib/display/TextSprite.d.ts +16 -16
- package/dist/lib/display/TextSprite.js +36 -36
- package/dist/lib/elements/SkyboxElements.d.ts +29 -29
- package/dist/lib/elements/SkyboxElements.js +127 -127
- package/dist/lib/errors/CastError.d.ts +4 -4
- package/dist/lib/errors/CastError.js +10 -10
- package/dist/lib/events/CameraEvent.d.ts +16 -16
- package/dist/lib/events/CameraEvent.js +30 -30
- package/dist/lib/events/FocusEvent.d.ts +42 -42
- package/dist/lib/events/FocusEvent.js +43 -43
- package/dist/lib/events/KeyboardEvent.d.ts +21 -21
- package/dist/lib/events/KeyboardEvent.js +43 -43
- package/dist/lib/events/MouseEvent.d.ts +91 -91
- package/dist/lib/events/MouseEvent.js +122 -122
- package/dist/lib/events/PointerEvent.d.ts +93 -93
- package/dist/lib/events/PointerEvent.js +73 -73
- package/dist/lib/events/ResizeEvent.d.ts +15 -15
- package/dist/lib/events/ResizeEvent.js +38 -38
- package/dist/lib/events/TextfieldEvent.d.ts +19 -19
- package/dist/lib/events/TextfieldEvent.js +28 -28
- package/dist/lib/events/TouchEvent.d.ts +54 -54
- package/dist/lib/events/TouchEvent.js +89 -89
- package/dist/lib/factories/DefaultSceneGraphFactory.d.ts +27 -27
- package/dist/lib/factories/DefaultSceneGraphFactory.js +55 -55
- package/dist/lib/factories/ISceneGraphFactory.d.ts +20 -20
- package/dist/lib/factories/ISceneGraphFactory.js +1 -1
- package/dist/lib/image/SceneImage2D.d.ts +221 -220
- package/dist/lib/image/SceneImage2D.d.ts.map +1 -1
- package/dist/lib/image/SceneImage2D.js +609 -610
- package/dist/lib/managers/DefaultFontManager.d.ts +14 -14
- package/dist/lib/managers/DefaultFontManager.js +101 -101
- package/dist/lib/managers/DeviceFontManager.d.ts +8 -8
- package/dist/lib/managers/DeviceFontManager.js +44 -44
- package/dist/lib/managers/FrameScriptManager.d.ts +37 -37
- package/dist/lib/managers/FrameScriptManager.js +386 -386
- package/dist/lib/managers/IInputRecorder.d.ts +3 -3
- package/dist/lib/managers/IInputRecorder.js +1 -1
- package/dist/lib/managers/MouseManager.d.ts +74 -74
- package/dist/lib/managers/MouseManager.js +803 -803
- package/dist/lib/prefabs/PrefabBase.d.ts +19 -19
- package/dist/lib/prefabs/PrefabBase.js +42 -42
- package/dist/lib/prefabs/PrimitiveCapsulePrefab.d.ts +56 -56
- package/dist/lib/prefabs/PrimitiveCapsulePrefab.js +269 -269
- package/dist/lib/prefabs/PrimitiveConePrefab.d.ts +21 -21
- package/dist/lib/prefabs/PrimitiveConePrefab.js +43 -43
- package/dist/lib/prefabs/PrimitiveCubePrefab.d.ts +74 -74
- package/dist/lib/prefabs/PrimitiveCubePrefab.js +545 -545
- package/dist/lib/prefabs/PrimitiveCylinderPrefab.d.ts +79 -79
- package/dist/lib/prefabs/PrimitiveCylinderPrefab.js +584 -584
- package/dist/lib/prefabs/PrimitivePlanePrefab.d.ts +65 -65
- package/dist/lib/prefabs/PrimitivePlanePrefab.js +300 -300
- package/dist/lib/prefabs/PrimitivePolygonPrefab.d.ts +29 -29
- package/dist/lib/prefabs/PrimitivePolygonPrefab.js +64 -64
- package/dist/lib/prefabs/PrimitivePrefabBase.d.ts +67 -67
- package/dist/lib/prefabs/PrimitivePrefabBase.js +158 -158
- package/dist/lib/prefabs/PrimitiveSpherePrefab.d.ts +48 -48
- package/dist/lib/prefabs/PrimitiveSpherePrefab.js +294 -294
- package/dist/lib/prefabs/PrimitiveTorusPrefab.d.ts +55 -55
- package/dist/lib/prefabs/PrimitiveTorusPrefab.js +260 -260
- package/dist/lib/text/AntiAliasType.d.ts +24 -24
- package/dist/lib/text/AntiAliasType.js +28 -28
- package/dist/lib/text/BitmapFontChar.d.ts +39 -39
- package/dist/lib/text/BitmapFontChar.js +42 -42
- package/dist/lib/text/BitmapFontTable.d.ts +73 -73
- package/dist/lib/text/BitmapFontTable.js +183 -183
- package/dist/lib/text/FNTGenerator.d.ts +10 -10
- package/dist/lib/text/FNTGenerator.js +74 -74
- package/dist/lib/text/FNTGeneratorCanvas.d.ts +22 -22
- package/dist/lib/text/FNTGeneratorCanvas.js +211 -211
- package/dist/lib/text/FNTGeneratrorBase.d.ts +7 -7
- package/dist/lib/text/FNTGeneratrorBase.js +7 -7
- package/dist/lib/text/Font.d.ts +38 -38
- package/dist/lib/text/Font.js +109 -109
- package/dist/lib/text/FontLookUpMode.d.ts +5 -5
- package/dist/lib/text/FontLookUpMode.js +7 -7
- package/dist/lib/text/FontStyleName.d.ts +6 -6
- package/dist/lib/text/FontStyleName.js +7 -7
- package/dist/lib/text/GridFitType.d.ts +31 -31
- package/dist/lib/text/GridFitType.js +35 -35
- package/dist/lib/text/HTMLTextProcessor.d.ts +8 -8
- package/dist/lib/text/HTMLTextProcessor.js +426 -426
- package/dist/lib/text/IFontTable.d.ts +16 -16
- package/dist/lib/text/IFontTable.js +1 -1
- package/dist/lib/text/TesselatedFontChar.d.ts +58 -58
- package/dist/lib/text/TesselatedFontChar.js +66 -66
- package/dist/lib/text/TesselatedFontTable.d.ts +88 -88
- package/dist/lib/text/TesselatedFontTable.js +963 -963
- package/dist/lib/text/TextFieldAutoSize.d.ts +28 -28
- package/dist/lib/text/TextFieldAutoSize.js +32 -32
- package/dist/lib/text/TextFieldType.d.ts +20 -20
- package/dist/lib/text/TextFieldType.js +24 -24
- package/dist/lib/text/TextFormat.d.ts +273 -273
- package/dist/lib/text/TextFormat.js +449 -449
- package/dist/lib/text/TextFormatAlign.d.ts +26 -26
- package/dist/lib/text/TextFormatAlign.js +30 -30
- package/dist/lib/text/TextInteractionMode.d.ts +21 -21
- package/dist/lib/text/TextInteractionMode.js +25 -25
- package/dist/lib/text/TextLineMetrics.d.ts +61 -61
- package/dist/lib/text/TextLineMetrics.js +42 -42
- package/dist/lib/text/TextShape.d.ts +22 -22
- package/dist/lib/text/TextShape.js +75 -75
- package/dist/lib/tools/Merge.d.ts +81 -81
- package/dist/lib/tools/Merge.js +266 -266
- package/dist/lib/utils/Cast.d.ts +20 -20
- package/dist/lib/utils/Cast.js +271 -271
- package/index.ts +92 -92
- package/lib/Scene.ts +340 -339
- package/lib/Settings.ts +77 -83
- package/lib/adapters/IDisplayObjectAdapter.ts +23 -23
- package/lib/adapters/IFilter.ts +25 -25
- package/lib/adapters/IMovieClipAdapter.ts +26 -26
- package/lib/adapters/ITextfieldAdapter.ts +6 -6
- package/lib/base/IBitmapDrawable.ts +13 -13
- package/lib/base/IFrameLabel.ts +3 -3
- package/lib/base/IFrameScript.ts +4 -4
- package/lib/base/MouseButtons.ts +31 -31
- package/lib/base/Timeline.ts +715 -715
- package/lib/base/TimelineActionType.ts +18 -18
- package/lib/controllers/ControllerBase.ts +66 -66
- package/lib/controllers/FirstPersonController.ts +241 -241
- package/lib/controllers/FollowController.ts +22 -22
- package/lib/controllers/HoverController.ts +304 -304
- package/lib/controllers/LookAtController.ts +75 -75
- package/lib/controllers/SpringController.ts +91 -91
- package/lib/display/Billboard.ts +468 -468
- package/lib/display/Camera.ts +75 -75
- package/lib/display/DisplayObject.ts +1843 -1829
- package/lib/display/DisplayObjectContainer.ts +546 -546
- package/lib/display/LineSegment.ts +229 -229
- package/lib/display/LoaderContainer.ts +651 -651
- package/lib/display/MorphSprite.ts +339 -339
- package/lib/display/MovieClip.ts +870 -870
- package/lib/display/SimpleButton.ts +224 -224
- package/lib/display/Skybox.ts +352 -352
- package/lib/display/Sprite.ts +154 -154
- package/lib/display/TextField.ts +3876 -3876
- package/lib/display/TextSprite.ts +34 -34
- package/lib/elements/SkyboxElements.ts +141 -141
- package/lib/errors/CastError.ts +6 -6
- package/lib/events/CameraEvent.ts +29 -29
- package/lib/events/FocusEvent.ts +69 -69
- package/lib/events/KeyboardEvent.ts +40 -40
- package/lib/events/MouseEvent.ts +144 -144
- package/lib/events/PointerEvent.ts +145 -145
- package/lib/events/ResizeEvent.ts +31 -31
- package/lib/events/TextfieldEvent.ts +28 -28
- package/lib/events/TouchEvent.ts +103 -103
- package/lib/factories/DefaultSceneGraphFactory.ts +58 -58
- package/lib/factories/ISceneGraphFactory.ts +28 -28
- package/lib/image/SceneImage2D.ts +912 -912
- package/lib/managers/DefaultFontManager.ts +124 -124
- package/lib/managers/DeviceFontManager.ts +55 -55
- package/lib/managers/FrameScriptManager.ts +440 -440
- package/lib/managers/IInputRecorder.ts +2 -2
- package/lib/managers/MouseManager.ts +942 -942
- package/lib/prefabs/PrefabBase.ts +47 -47
- package/lib/prefabs/PrimitiveCapsulePrefab.ts +286 -286
- package/lib/prefabs/PrimitiveConePrefab.ts +37 -37
- package/lib/prefabs/PrimitiveCubePrefab.ts +630 -630
- package/lib/prefabs/PrimitiveCylinderPrefab.ts +657 -657
- package/lib/prefabs/PrimitivePlanePrefab.ts +352 -352
- package/lib/prefabs/PrimitivePolygonPrefab.ts +53 -53
- package/lib/prefabs/PrimitivePrefabBase.ts +177 -177
- package/lib/prefabs/PrimitiveSpherePrefab.ts +336 -336
- package/lib/prefabs/PrimitiveTorusPrefab.ts +282 -282
- package/lib/text/AntiAliasType.ts +24 -24
- package/lib/text/BitmapFontChar.ts +53 -53
- package/lib/text/BitmapFontTable.ts +213 -213
- package/lib/text/FNTGenerator.ts +100 -100
- package/lib/text/FNTGeneratorCanvas.ts +292 -292
- package/lib/text/FNTGeneratrorBase.ts +10 -10
- package/lib/text/Font.ts +114 -114
- package/lib/text/FontLookUpMode.ts +5 -5
- package/lib/text/FontStyleName.ts +6 -6
- package/lib/text/GridFitType.ts +32 -32
- package/lib/text/HTMLTextProcessor.ts +421 -421
- package/lib/text/IFontTable.ts +17 -17
- package/lib/text/TesselatedFontChar.ts +80 -80
- package/lib/text/TesselatedFontTable.ts +1181 -1181
- package/lib/text/TextFieldAutoSize.ts +30 -30
- package/lib/text/TextFieldType.ts +21 -21
- package/lib/text/TextFormat.ts +603 -603
- package/lib/text/TextFormatAlign.ts +28 -28
- package/lib/text/TextInteractionMode.ts +21 -21
- package/lib/text/TextLineMetrics.ts +74 -74
- package/lib/text/TextShape.ts +91 -91
- package/lib/tools/Merge.ts +311 -311
- package/lib/utils/Cast.ts +304 -304
- package/package.json +74 -74
- package/rollup.config.js +33 -33
- package/scripts/build.sh +2 -2
- package/scripts/gendocs.sh +14 -14
- package/scripts/genexamples.sh +14 -14
- package/scripts/genfull.sh +14 -14
- package/system.config.js +51 -51
- package/tsconfig.json +18 -18
|
@@ -1,922 +1,927 @@
|
|
|
1
|
-
import { Transform, Matrix3D, Rectangle, Vector3D, AssetBase, Loader } from '@awayjs/core';
|
|
2
|
-
import { BlendMode } from '@awayjs/stage';
|
|
3
|
-
import { BoundingVolumeType, IEntity, BoundsPicker, HierarchicalProperty, AlignmentMode, OrientationMode, IContainer, ContainerNode } from '@awayjs/view';
|
|
4
|
-
import { IMaterial, Style, StyleEvent, RenderEntity, _Render_RenderableBase, CacheRenderer } from '@awayjs/renderer';
|
|
5
|
-
import { DisplayObjectContainer } from './DisplayObjectContainer';
|
|
6
|
-
import { ControllerBase } from '../controllers/ControllerBase';
|
|
7
|
-
import { IBitmapDrawable } from '../base/IBitmapDrawable';
|
|
8
|
-
import { IFilter } from '../adapters/IFilter';
|
|
9
|
-
/**
|
|
10
|
-
* The DisplayObject class is the base class for all objects that can be
|
|
11
|
-
* placed on the display list. The display list manages all objects displayed
|
|
12
|
-
* in flash. Use the DisplayObjectContainer class to arrange the
|
|
13
|
-
* display objects in the display list. DisplayObjectContainer objects can
|
|
14
|
-
* have child display objects, while other display objects, such as Shape and
|
|
15
|
-
* TextField objects, are "leaf" nodes that have only parents and siblings, no
|
|
16
|
-
* children.
|
|
17
|
-
*
|
|
18
|
-
* <p>The DisplayObject class supports fbasic functionality like the <i>x</i>
|
|
19
|
-
* and <i>y</i> position of an object, as well as more advanced properties of
|
|
20
|
-
* the object such as its transformation matrix. </p>
|
|
21
|
-
*
|
|
22
|
-
* <p>DisplayObject is an abstract base class; therefore, you cannot call
|
|
23
|
-
* DisplayObject directly. Invoking <code>new DisplayObject()</code> throws an
|
|
24
|
-
* <code>ArgumentError</code> exception. </p>
|
|
25
|
-
*
|
|
26
|
-
* <p>All display objects inherit from the DisplayObject class.</p>
|
|
27
|
-
*
|
|
28
|
-
* <p>The DisplayObject class itself does not include any APIs for rendering
|
|
29
|
-
* content onscreen. For that reason, if you want create a custom subclass of
|
|
30
|
-
* the DisplayObject class, you will want to extend one of its subclasses that
|
|
31
|
-
* do have APIs for rendering content onscreen, such as the Shape, Sprite,
|
|
32
|
-
* Bitmap, SimpleButton, TextField, or MovieClip class.</p>
|
|
33
|
-
*
|
|
34
|
-
* <p>The DisplayObject class contains several broadcast events. Normally, the
|
|
35
|
-
* target of any particular event is a specific DisplayObject instance. For
|
|
36
|
-
* example, the target of an <code>added</code> event is the specific
|
|
37
|
-
* DisplayObject instance that was added to the display list. Having a single
|
|
38
|
-
* target restricts the placement of event listeners to that target and in
|
|
39
|
-
* some cases the target's ancestors on the display list. With broadcast
|
|
40
|
-
* events, however, the target is not a specific DisplayObject instance, but
|
|
41
|
-
* rather all DisplayObject instances, including those that are not on the
|
|
42
|
-
* display list. This means that you can add a listener to any DisplayObject
|
|
43
|
-
* instance to listen for broadcast events. In addition to the broadcast
|
|
44
|
-
* events listed in the DisplayObject class's Events table, the DisplayObject
|
|
45
|
-
* class also inherits two broadcast events from the EventDispatcher class:
|
|
46
|
-
* <code>activate</code> and <code>deactivate</code>.</p>
|
|
47
|
-
*
|
|
48
|
-
* <p>Some properties previously used in the ActionScript 1.0 and 2.0
|
|
49
|
-
* MovieClip, TextField, and Button classes(such as <code>_alpha</code>,
|
|
50
|
-
* <code>_height</code>, <code>_pName</code>, <code>_width</code>,
|
|
51
|
-
* <code>_x</code>, <code>_y</code>, and others) have equivalents in the
|
|
52
|
-
* ActionScript 3.0 DisplayObject class that are renamed so that they no
|
|
53
|
-
* longer begin with the underscore(_) character.</p>
|
|
54
|
-
*
|
|
55
|
-
* <p>For more information, see the "Display Programming" chapter of the
|
|
56
|
-
* <i>ActionScript 3.0 Developer's Guide</i>.</p>
|
|
57
|
-
*
|
|
58
|
-
* @event added Dispatched when a display object is added to the
|
|
59
|
-
* display list. The following methods trigger this
|
|
60
|
-
* event:
|
|
61
|
-
* <code>DisplayObjectContainer.addChild()</code>,
|
|
62
|
-
* <code>DisplayObjectContainer.addChildAt()</code>.
|
|
63
|
-
* @event addedToScene Dispatched when a display object is added to the on
|
|
64
|
-
* scene display list, either directly or through the
|
|
65
|
-
* addition of a sub tree in which the display object
|
|
66
|
-
* is contained. The following methods trigger this
|
|
67
|
-
* event:
|
|
68
|
-
* <code>DisplayObjectContainer.addChild()</code>,
|
|
69
|
-
* <code>DisplayObjectContainer.addChildAt()</code>.
|
|
70
|
-
* @event enterFrame [broadcast event] Dispatched when the playhead is
|
|
71
|
-
* entering a new frame. If the playhead is not
|
|
72
|
-
* moving, or if there is only one frame, this event
|
|
73
|
-
* is dispatched continuously in conjunction with the
|
|
74
|
-
* frame rate. This event is a broadcast event, which
|
|
75
|
-
* means that it is dispatched by all display objects
|
|
76
|
-
* with a listener registered for this event.
|
|
77
|
-
* @event exitFrame [broadcast event] Dispatched when the playhead is
|
|
78
|
-
* exiting the current frame. All frame scripts have
|
|
79
|
-
* been run. If the playhead is not moving, or if
|
|
80
|
-
* there is only one frame, this event is dispatched
|
|
81
|
-
* continuously in conjunction with the frame rate.
|
|
82
|
-
* This event is a broadcast event, which means that
|
|
83
|
-
* it is dispatched by all display objects with a
|
|
84
|
-
* listener registered for this event.
|
|
85
|
-
* @event frameConstructed [broadcast event] Dispatched after the constructors
|
|
86
|
-
* of frame display objects have run but before frame
|
|
87
|
-
* scripts have run. If the playhead is not moving, or
|
|
88
|
-
* if there is only one frame, this event is
|
|
89
|
-
* dispatched continuously in conjunction with the
|
|
90
|
-
* frame rate. This event is a broadcast event, which
|
|
91
|
-
* means that it is dispatched by all display objects
|
|
92
|
-
* with a listener registered for this event.
|
|
93
|
-
* @event removed Dispatched when a display object is about to be
|
|
94
|
-
* removed from the display list. Two methods of the
|
|
95
|
-
* DisplayObjectContainer class generate this event:
|
|
96
|
-
* <code>removeChild()</code> and
|
|
97
|
-
* <code>removeChildAt()</code>.
|
|
98
|
-
*
|
|
99
|
-
* <p>The following methods of a
|
|
100
|
-
* DisplayObjectContainer object also generate this
|
|
101
|
-
* event if an object must be removed to make room for
|
|
102
|
-
* the new object: <code>addChild()</code>,
|
|
103
|
-
* <code>addChildAt()</code>, and
|
|
104
|
-
* <code>setChildIndex()</code>. </p>
|
|
105
|
-
* @event removedFromScene Dispatched when a display object is about to be
|
|
106
|
-
* removed from the display list, either directly or
|
|
107
|
-
* through the removal of a sub tree in which the
|
|
108
|
-
* display object is contained. Two methods of the
|
|
109
|
-
* DisplayObjectContainer class generate this event:
|
|
110
|
-
* <code>removeChild()</code> and
|
|
111
|
-
* <code>removeChildAt()</code>.
|
|
112
|
-
*
|
|
113
|
-
* <p>The following methods of a
|
|
114
|
-
* DisplayObjectContainer object also generate this
|
|
115
|
-
* event if an object must be removed to make room for
|
|
116
|
-
* the new object: <code>addChild()</code>,
|
|
117
|
-
* <code>addChildAt()</code>, and
|
|
118
|
-
* <code>setChildIndex()</code>. </p>
|
|
119
|
-
* @event render [broadcast event] Dispatched when the display list
|
|
120
|
-
* is about to be updated and rendered. This event
|
|
121
|
-
* provides the last opportunity for objects listening
|
|
122
|
-
* for this event to make changes before the display
|
|
123
|
-
* list is rendered. You must call the
|
|
124
|
-
* <code>invalidate()</code> method of the Scene
|
|
125
|
-
* object each time you want a <code>render</code>
|
|
126
|
-
* event to be dispatched. <code>Render</code> events
|
|
127
|
-
* are dispatched to an object only if there is mutual
|
|
128
|
-
* trust between it and the object that called
|
|
129
|
-
* <code>Scene.invalidate()</code>. This event is a
|
|
130
|
-
* broadcast event, which means that it is dispatched
|
|
131
|
-
* by all display objects with a listener registered
|
|
132
|
-
* for this event.
|
|
133
|
-
*
|
|
134
|
-
* <p><b>Note: </b>This event is not dispatched if the
|
|
135
|
-
* display is not rendering. This is the case when the
|
|
136
|
-
* content is either minimized or obscured. </p>
|
|
137
|
-
*/
|
|
138
|
-
export declare class DisplayObject extends AssetBase implements IBitmapDrawable, IContainer {
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
private
|
|
147
|
-
private
|
|
148
|
-
private
|
|
149
|
-
private
|
|
150
|
-
private
|
|
151
|
-
private
|
|
152
|
-
private
|
|
153
|
-
private
|
|
154
|
-
private
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
private
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
private
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
protected
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
private
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
get
|
|
189
|
-
set
|
|
190
|
-
get
|
|
191
|
-
set
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
*
|
|
202
|
-
*
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
*
|
|
210
|
-
* bitmap
|
|
211
|
-
*
|
|
212
|
-
*
|
|
213
|
-
*
|
|
214
|
-
* <
|
|
215
|
-
*
|
|
216
|
-
*
|
|
217
|
-
*
|
|
218
|
-
*
|
|
219
|
-
*
|
|
220
|
-
*
|
|
221
|
-
*
|
|
222
|
-
*
|
|
223
|
-
*
|
|
224
|
-
*
|
|
225
|
-
*
|
|
226
|
-
*
|
|
227
|
-
*
|
|
228
|
-
*
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
*
|
|
242
|
-
*
|
|
243
|
-
*
|
|
244
|
-
*
|
|
245
|
-
*
|
|
246
|
-
*
|
|
247
|
-
* <
|
|
248
|
-
*
|
|
249
|
-
*
|
|
250
|
-
*
|
|
251
|
-
*
|
|
252
|
-
*
|
|
253
|
-
*
|
|
254
|
-
*
|
|
255
|
-
*
|
|
256
|
-
* object to the
|
|
257
|
-
*
|
|
258
|
-
*
|
|
259
|
-
*
|
|
260
|
-
*
|
|
261
|
-
*
|
|
262
|
-
*
|
|
263
|
-
*
|
|
264
|
-
*
|
|
265
|
-
*
|
|
266
|
-
*
|
|
267
|
-
*
|
|
268
|
-
*
|
|
269
|
-
*
|
|
270
|
-
*
|
|
271
|
-
* <code>
|
|
272
|
-
* <code>
|
|
273
|
-
* <code>
|
|
274
|
-
*
|
|
275
|
-
* <
|
|
276
|
-
*
|
|
277
|
-
*
|
|
278
|
-
*
|
|
279
|
-
*
|
|
280
|
-
*
|
|
281
|
-
*
|
|
282
|
-
*
|
|
283
|
-
* is 8,191 pixels
|
|
284
|
-
*
|
|
285
|
-
*
|
|
286
|
-
*
|
|
287
|
-
*
|
|
288
|
-
*
|
|
289
|
-
*
|
|
290
|
-
*
|
|
291
|
-
*
|
|
292
|
-
*
|
|
293
|
-
*
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
*
|
|
316
|
-
*
|
|
317
|
-
*
|
|
318
|
-
*
|
|
319
|
-
*
|
|
320
|
-
*
|
|
321
|
-
*
|
|
322
|
-
*
|
|
323
|
-
*
|
|
324
|
-
*
|
|
325
|
-
*
|
|
326
|
-
* <
|
|
327
|
-
*
|
|
328
|
-
* <
|
|
329
|
-
*
|
|
330
|
-
*
|
|
331
|
-
* <li>
|
|
332
|
-
*
|
|
333
|
-
* <li>
|
|
334
|
-
* array
|
|
335
|
-
* <li>
|
|
336
|
-
*
|
|
337
|
-
*
|
|
338
|
-
*
|
|
339
|
-
*
|
|
340
|
-
*
|
|
341
|
-
*
|
|
342
|
-
*
|
|
343
|
-
*
|
|
344
|
-
*
|
|
345
|
-
*
|
|
346
|
-
*
|
|
347
|
-
*
|
|
348
|
-
* <
|
|
349
|
-
*
|
|
350
|
-
*
|
|
351
|
-
* <li>
|
|
352
|
-
* <code>myFilters</code
|
|
353
|
-
*
|
|
354
|
-
* <code>myFilters
|
|
355
|
-
*
|
|
356
|
-
*
|
|
357
|
-
* </
|
|
358
|
-
*
|
|
359
|
-
*
|
|
360
|
-
*
|
|
361
|
-
*
|
|
362
|
-
*
|
|
363
|
-
*
|
|
364
|
-
*
|
|
365
|
-
*
|
|
366
|
-
*
|
|
367
|
-
*
|
|
368
|
-
*
|
|
369
|
-
*
|
|
370
|
-
*
|
|
371
|
-
*
|
|
372
|
-
*
|
|
373
|
-
*
|
|
374
|
-
*
|
|
375
|
-
*
|
|
376
|
-
*
|
|
377
|
-
*
|
|
378
|
-
*
|
|
379
|
-
*
|
|
380
|
-
*
|
|
381
|
-
*
|
|
382
|
-
*
|
|
383
|
-
*
|
|
384
|
-
*
|
|
385
|
-
*
|
|
386
|
-
*
|
|
387
|
-
*
|
|
388
|
-
*
|
|
389
|
-
*
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
*
|
|
399
|
-
* container
|
|
400
|
-
*
|
|
401
|
-
*
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
*
|
|
408
|
-
*
|
|
409
|
-
*
|
|
410
|
-
* a
|
|
411
|
-
* <code>
|
|
412
|
-
*
|
|
413
|
-
* <
|
|
414
|
-
*
|
|
415
|
-
*
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
*
|
|
422
|
-
*
|
|
423
|
-
* <code>mask</code>
|
|
424
|
-
*
|
|
425
|
-
* <
|
|
426
|
-
*
|
|
427
|
-
* <
|
|
428
|
-
*
|
|
429
|
-
* <code>
|
|
430
|
-
*
|
|
431
|
-
*
|
|
432
|
-
* <
|
|
433
|
-
*
|
|
434
|
-
* <
|
|
435
|
-
*
|
|
436
|
-
*
|
|
437
|
-
*
|
|
438
|
-
* display
|
|
439
|
-
*
|
|
440
|
-
* cached, then the mask must be a
|
|
441
|
-
*
|
|
442
|
-
*
|
|
443
|
-
*
|
|
444
|
-
*
|
|
445
|
-
*
|
|
446
|
-
*
|
|
447
|
-
*
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
get
|
|
452
|
-
set
|
|
453
|
-
get
|
|
454
|
-
set
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
*
|
|
459
|
-
*
|
|
460
|
-
*
|
|
461
|
-
*
|
|
462
|
-
*
|
|
463
|
-
*
|
|
464
|
-
* children of
|
|
465
|
-
* <code>
|
|
466
|
-
*
|
|
467
|
-
* <
|
|
468
|
-
*
|
|
469
|
-
*
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
*
|
|
477
|
-
*
|
|
478
|
-
*
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
*
|
|
485
|
-
*
|
|
486
|
-
*
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
*
|
|
493
|
-
* container
|
|
494
|
-
*
|
|
495
|
-
*
|
|
496
|
-
*
|
|
497
|
-
*
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
*
|
|
509
|
-
*
|
|
510
|
-
*
|
|
511
|
-
*
|
|
512
|
-
*
|
|
513
|
-
*
|
|
514
|
-
*
|
|
515
|
-
*
|
|
516
|
-
*
|
|
517
|
-
*
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
*
|
|
534
|
-
*
|
|
535
|
-
*
|
|
536
|
-
* the <code>root</code> property is the
|
|
537
|
-
*
|
|
538
|
-
*
|
|
539
|
-
*
|
|
540
|
-
*
|
|
541
|
-
*
|
|
542
|
-
*
|
|
543
|
-
*
|
|
544
|
-
*
|
|
545
|
-
*
|
|
546
|
-
*
|
|
547
|
-
*
|
|
548
|
-
*
|
|
549
|
-
*
|
|
550
|
-
*
|
|
551
|
-
* SWF file
|
|
552
|
-
*
|
|
553
|
-
*
|
|
554
|
-
* set
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
*
|
|
561
|
-
*
|
|
562
|
-
*
|
|
563
|
-
*
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
*
|
|
570
|
-
*
|
|
571
|
-
*
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
*
|
|
579
|
-
*
|
|
580
|
-
*
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
*
|
|
588
|
-
*
|
|
589
|
-
*
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
* is
|
|
597
|
-
*
|
|
598
|
-
*
|
|
599
|
-
*
|
|
600
|
-
* <code>scale9Grid</code>
|
|
601
|
-
*
|
|
602
|
-
*
|
|
603
|
-
*
|
|
604
|
-
*
|
|
605
|
-
*
|
|
606
|
-
* <li>The upper-
|
|
607
|
-
* <li>The area
|
|
608
|
-
* <li>The
|
|
609
|
-
* <li>The
|
|
610
|
-
* <li>The area
|
|
611
|
-
* <li>The lower-
|
|
612
|
-
* </
|
|
613
|
-
*
|
|
614
|
-
*
|
|
615
|
-
*
|
|
616
|
-
*
|
|
617
|
-
*
|
|
618
|
-
*
|
|
619
|
-
*
|
|
620
|
-
*
|
|
621
|
-
*
|
|
622
|
-
*
|
|
623
|
-
*
|
|
624
|
-
*
|
|
625
|
-
* <li>Content in the
|
|
626
|
-
*
|
|
627
|
-
* <li>
|
|
628
|
-
*
|
|
629
|
-
*
|
|
630
|
-
*
|
|
631
|
-
*
|
|
632
|
-
*
|
|
633
|
-
*
|
|
634
|
-
* <
|
|
635
|
-
*
|
|
636
|
-
*
|
|
637
|
-
*
|
|
638
|
-
*
|
|
639
|
-
*
|
|
640
|
-
*
|
|
641
|
-
*
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
*
|
|
649
|
-
*
|
|
650
|
-
*
|
|
651
|
-
*
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
*
|
|
659
|
-
*
|
|
660
|
-
*
|
|
661
|
-
*
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
*
|
|
669
|
-
*
|
|
670
|
-
*
|
|
671
|
-
*
|
|
672
|
-
*
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
* rectangle
|
|
698
|
-
*
|
|
699
|
-
*
|
|
700
|
-
*
|
|
701
|
-
*
|
|
702
|
-
*
|
|
703
|
-
* display object
|
|
704
|
-
*
|
|
705
|
-
*
|
|
706
|
-
* the
|
|
707
|
-
*
|
|
708
|
-
*
|
|
709
|
-
*
|
|
710
|
-
*
|
|
711
|
-
* an object
|
|
712
|
-
* <code>scrollRect</code> Rectangle object.
|
|
713
|
-
*
|
|
714
|
-
*
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
*
|
|
739
|
-
*
|
|
740
|
-
* and
|
|
741
|
-
*
|
|
742
|
-
*
|
|
743
|
-
*
|
|
744
|
-
*
|
|
745
|
-
*
|
|
746
|
-
*
|
|
747
|
-
*
|
|
748
|
-
*
|
|
749
|
-
*
|
|
750
|
-
*
|
|
751
|
-
*
|
|
752
|
-
*
|
|
753
|
-
*
|
|
754
|
-
*
|
|
755
|
-
*
|
|
756
|
-
*
|
|
757
|
-
* <
|
|
758
|
-
*
|
|
759
|
-
*
|
|
760
|
-
*
|
|
761
|
-
*
|
|
762
|
-
*
|
|
763
|
-
*
|
|
764
|
-
* <code>
|
|
765
|
-
*
|
|
766
|
-
* <
|
|
767
|
-
*
|
|
768
|
-
* display object, <code>
|
|
769
|
-
*
|
|
770
|
-
* <p>
|
|
771
|
-
*
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
*
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
*
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
*
|
|
792
|
-
*
|
|
793
|
-
*
|
|
794
|
-
* <
|
|
795
|
-
*
|
|
796
|
-
*
|
|
797
|
-
*
|
|
798
|
-
*
|
|
799
|
-
*
|
|
800
|
-
*
|
|
801
|
-
*
|
|
802
|
-
*
|
|
803
|
-
*
|
|
804
|
-
*
|
|
805
|
-
*
|
|
806
|
-
*
|
|
807
|
-
*
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
*
|
|
815
|
-
*
|
|
816
|
-
*
|
|
817
|
-
*
|
|
818
|
-
* rotated 90° counterclockwise
|
|
819
|
-
*
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
*
|
|
827
|
-
*
|
|
828
|
-
*
|
|
829
|
-
*
|
|
830
|
-
* rotated 90° counterclockwise
|
|
831
|
-
*
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
*
|
|
839
|
-
*
|
|
840
|
-
*
|
|
841
|
-
*
|
|
842
|
-
*
|
|
843
|
-
*
|
|
844
|
-
*
|
|
845
|
-
*
|
|
846
|
-
*
|
|
847
|
-
*
|
|
848
|
-
*
|
|
849
|
-
*
|
|
850
|
-
*
|
|
851
|
-
*
|
|
852
|
-
*
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
*
|
|
881
|
-
*
|
|
882
|
-
*
|
|
883
|
-
*
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
*
|
|
890
|
-
*
|
|
891
|
-
* @param
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
protected
|
|
913
|
-
|
|
914
|
-
protected
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
protected
|
|
921
|
-
|
|
1
|
+
import { Transform, Matrix3D, Rectangle, Vector3D, AssetBase, Loader, IAbstractionPool, IAsset, IAbstraction, AbstractionSet } from '@awayjs/core';
|
|
2
|
+
import { BlendMode } from '@awayjs/stage';
|
|
3
|
+
import { BoundingVolumeType, IEntity, BoundsPicker, HierarchicalProperty, AlignmentMode, OrientationMode, IContainer, ContainerNode } from '@awayjs/view';
|
|
4
|
+
import { IMaterial, Style, StyleEvent, RenderEntity, _Render_RenderableBase, CacheRenderer } from '@awayjs/renderer';
|
|
5
|
+
import { DisplayObjectContainer } from './DisplayObjectContainer';
|
|
6
|
+
import { ControllerBase } from '../controllers/ControllerBase';
|
|
7
|
+
import { IBitmapDrawable } from '../base/IBitmapDrawable';
|
|
8
|
+
import { IFilter } from '../adapters/IFilter';
|
|
9
|
+
/**
|
|
10
|
+
* The DisplayObject class is the base class for all objects that can be
|
|
11
|
+
* placed on the display list. The display list manages all objects displayed
|
|
12
|
+
* in flash. Use the DisplayObjectContainer class to arrange the
|
|
13
|
+
* display objects in the display list. DisplayObjectContainer objects can
|
|
14
|
+
* have child display objects, while other display objects, such as Shape and
|
|
15
|
+
* TextField objects, are "leaf" nodes that have only parents and siblings, no
|
|
16
|
+
* children.
|
|
17
|
+
*
|
|
18
|
+
* <p>The DisplayObject class supports fbasic functionality like the <i>x</i>
|
|
19
|
+
* and <i>y</i> position of an object, as well as more advanced properties of
|
|
20
|
+
* the object such as its transformation matrix. </p>
|
|
21
|
+
*
|
|
22
|
+
* <p>DisplayObject is an abstract base class; therefore, you cannot call
|
|
23
|
+
* DisplayObject directly. Invoking <code>new DisplayObject()</code> throws an
|
|
24
|
+
* <code>ArgumentError</code> exception. </p>
|
|
25
|
+
*
|
|
26
|
+
* <p>All display objects inherit from the DisplayObject class.</p>
|
|
27
|
+
*
|
|
28
|
+
* <p>The DisplayObject class itself does not include any APIs for rendering
|
|
29
|
+
* content onscreen. For that reason, if you want create a custom subclass of
|
|
30
|
+
* the DisplayObject class, you will want to extend one of its subclasses that
|
|
31
|
+
* do have APIs for rendering content onscreen, such as the Shape, Sprite,
|
|
32
|
+
* Bitmap, SimpleButton, TextField, or MovieClip class.</p>
|
|
33
|
+
*
|
|
34
|
+
* <p>The DisplayObject class contains several broadcast events. Normally, the
|
|
35
|
+
* target of any particular event is a specific DisplayObject instance. For
|
|
36
|
+
* example, the target of an <code>added</code> event is the specific
|
|
37
|
+
* DisplayObject instance that was added to the display list. Having a single
|
|
38
|
+
* target restricts the placement of event listeners to that target and in
|
|
39
|
+
* some cases the target's ancestors on the display list. With broadcast
|
|
40
|
+
* events, however, the target is not a specific DisplayObject instance, but
|
|
41
|
+
* rather all DisplayObject instances, including those that are not on the
|
|
42
|
+
* display list. This means that you can add a listener to any DisplayObject
|
|
43
|
+
* instance to listen for broadcast events. In addition to the broadcast
|
|
44
|
+
* events listed in the DisplayObject class's Events table, the DisplayObject
|
|
45
|
+
* class also inherits two broadcast events from the EventDispatcher class:
|
|
46
|
+
* <code>activate</code> and <code>deactivate</code>.</p>
|
|
47
|
+
*
|
|
48
|
+
* <p>Some properties previously used in the ActionScript 1.0 and 2.0
|
|
49
|
+
* MovieClip, TextField, and Button classes(such as <code>_alpha</code>,
|
|
50
|
+
* <code>_height</code>, <code>_pName</code>, <code>_width</code>,
|
|
51
|
+
* <code>_x</code>, <code>_y</code>, and others) have equivalents in the
|
|
52
|
+
* ActionScript 3.0 DisplayObject class that are renamed so that they no
|
|
53
|
+
* longer begin with the underscore(_) character.</p>
|
|
54
|
+
*
|
|
55
|
+
* <p>For more information, see the "Display Programming" chapter of the
|
|
56
|
+
* <i>ActionScript 3.0 Developer's Guide</i>.</p>
|
|
57
|
+
*
|
|
58
|
+
* @event added Dispatched when a display object is added to the
|
|
59
|
+
* display list. The following methods trigger this
|
|
60
|
+
* event:
|
|
61
|
+
* <code>DisplayObjectContainer.addChild()</code>,
|
|
62
|
+
* <code>DisplayObjectContainer.addChildAt()</code>.
|
|
63
|
+
* @event addedToScene Dispatched when a display object is added to the on
|
|
64
|
+
* scene display list, either directly or through the
|
|
65
|
+
* addition of a sub tree in which the display object
|
|
66
|
+
* is contained. The following methods trigger this
|
|
67
|
+
* event:
|
|
68
|
+
* <code>DisplayObjectContainer.addChild()</code>,
|
|
69
|
+
* <code>DisplayObjectContainer.addChildAt()</code>.
|
|
70
|
+
* @event enterFrame [broadcast event] Dispatched when the playhead is
|
|
71
|
+
* entering a new frame. If the playhead is not
|
|
72
|
+
* moving, or if there is only one frame, this event
|
|
73
|
+
* is dispatched continuously in conjunction with the
|
|
74
|
+
* frame rate. This event is a broadcast event, which
|
|
75
|
+
* means that it is dispatched by all display objects
|
|
76
|
+
* with a listener registered for this event.
|
|
77
|
+
* @event exitFrame [broadcast event] Dispatched when the playhead is
|
|
78
|
+
* exiting the current frame. All frame scripts have
|
|
79
|
+
* been run. If the playhead is not moving, or if
|
|
80
|
+
* there is only one frame, this event is dispatched
|
|
81
|
+
* continuously in conjunction with the frame rate.
|
|
82
|
+
* This event is a broadcast event, which means that
|
|
83
|
+
* it is dispatched by all display objects with a
|
|
84
|
+
* listener registered for this event.
|
|
85
|
+
* @event frameConstructed [broadcast event] Dispatched after the constructors
|
|
86
|
+
* of frame display objects have run but before frame
|
|
87
|
+
* scripts have run. If the playhead is not moving, or
|
|
88
|
+
* if there is only one frame, this event is
|
|
89
|
+
* dispatched continuously in conjunction with the
|
|
90
|
+
* frame rate. This event is a broadcast event, which
|
|
91
|
+
* means that it is dispatched by all display objects
|
|
92
|
+
* with a listener registered for this event.
|
|
93
|
+
* @event removed Dispatched when a display object is about to be
|
|
94
|
+
* removed from the display list. Two methods of the
|
|
95
|
+
* DisplayObjectContainer class generate this event:
|
|
96
|
+
* <code>removeChild()</code> and
|
|
97
|
+
* <code>removeChildAt()</code>.
|
|
98
|
+
*
|
|
99
|
+
* <p>The following methods of a
|
|
100
|
+
* DisplayObjectContainer object also generate this
|
|
101
|
+
* event if an object must be removed to make room for
|
|
102
|
+
* the new object: <code>addChild()</code>,
|
|
103
|
+
* <code>addChildAt()</code>, and
|
|
104
|
+
* <code>setChildIndex()</code>. </p>
|
|
105
|
+
* @event removedFromScene Dispatched when a display object is about to be
|
|
106
|
+
* removed from the display list, either directly or
|
|
107
|
+
* through the removal of a sub tree in which the
|
|
108
|
+
* display object is contained. Two methods of the
|
|
109
|
+
* DisplayObjectContainer class generate this event:
|
|
110
|
+
* <code>removeChild()</code> and
|
|
111
|
+
* <code>removeChildAt()</code>.
|
|
112
|
+
*
|
|
113
|
+
* <p>The following methods of a
|
|
114
|
+
* DisplayObjectContainer object also generate this
|
|
115
|
+
* event if an object must be removed to make room for
|
|
116
|
+
* the new object: <code>addChild()</code>,
|
|
117
|
+
* <code>addChildAt()</code>, and
|
|
118
|
+
* <code>setChildIndex()</code>. </p>
|
|
119
|
+
* @event render [broadcast event] Dispatched when the display list
|
|
120
|
+
* is about to be updated and rendered. This event
|
|
121
|
+
* provides the last opportunity for objects listening
|
|
122
|
+
* for this event to make changes before the display
|
|
123
|
+
* list is rendered. You must call the
|
|
124
|
+
* <code>invalidate()</code> method of the Scene
|
|
125
|
+
* object each time you want a <code>render</code>
|
|
126
|
+
* event to be dispatched. <code>Render</code> events
|
|
127
|
+
* are dispatched to an object only if there is mutual
|
|
128
|
+
* trust between it and the object that called
|
|
129
|
+
* <code>Scene.invalidate()</code>. This event is a
|
|
130
|
+
* broadcast event, which means that it is dispatched
|
|
131
|
+
* by all display objects with a listener registered
|
|
132
|
+
* for this event.
|
|
133
|
+
*
|
|
134
|
+
* <p><b>Note: </b>This event is not dispatched if the
|
|
135
|
+
* display is not rendering. This is the case when the
|
|
136
|
+
* content is either minimized or obscured. </p>
|
|
137
|
+
*/
|
|
138
|
+
export declare class DisplayObject extends AssetBase implements IBitmapDrawable, IContainer, IAbstractionPool {
|
|
139
|
+
private static _store;
|
|
140
|
+
readonly abstractions: AbstractionSet;
|
|
141
|
+
_renderObjects: Record<number, RenderEntity | _Render_RenderableBase | CacheRenderer>;
|
|
142
|
+
_containerNodes: Record<number, ContainerNode>;
|
|
143
|
+
private _mouseChildren;
|
|
144
|
+
_material: IMaterial;
|
|
145
|
+
_style: Style;
|
|
146
|
+
private _loader;
|
|
147
|
+
private _mouseX;
|
|
148
|
+
private _mouseY;
|
|
149
|
+
private _root;
|
|
150
|
+
private _boundsVisible;
|
|
151
|
+
private _boundsPrefab;
|
|
152
|
+
private _boundsPrefabDirty;
|
|
153
|
+
private _boundsPrimitive;
|
|
154
|
+
private _pName;
|
|
155
|
+
private _scrollRect;
|
|
156
|
+
private _scrollRectPrimitive;
|
|
157
|
+
protected _parent: DisplayObjectContainer;
|
|
158
|
+
_sessionID: number;
|
|
159
|
+
_avmDepthID: number;
|
|
160
|
+
pickObjectFromTimeline: boolean;
|
|
161
|
+
private _alignmentMode;
|
|
162
|
+
private _scale9Grid;
|
|
163
|
+
protected _transform: Transform;
|
|
164
|
+
private _visible;
|
|
165
|
+
private _maskId;
|
|
166
|
+
protected _timelineMasks: DisplayObject[] | undefined;
|
|
167
|
+
protected _mask: DisplayObject | undefined;
|
|
168
|
+
private _mouseEnabled;
|
|
169
|
+
private _eulers;
|
|
170
|
+
_registrationMatrix3D: Matrix3D;
|
|
171
|
+
private _defaultBoundingVolume;
|
|
172
|
+
cursorType: string;
|
|
173
|
+
protected _isInFocus: boolean;
|
|
174
|
+
protected _tabEnabled: boolean;
|
|
175
|
+
protected _tabIndex: number;
|
|
176
|
+
private _maskMode;
|
|
177
|
+
private _pickObject;
|
|
178
|
+
_hierarchicalPropsDirty: number;
|
|
179
|
+
private _onInvalidatePropertiesDelegate;
|
|
180
|
+
private _onInvalidateImagesDelegate;
|
|
181
|
+
isSlice9ScaledMC: boolean;
|
|
182
|
+
isSlice9ScaledSprite: boolean;
|
|
183
|
+
avm1Symbol: any;
|
|
184
|
+
isAVMScene: boolean;
|
|
185
|
+
placeObjectTag: any;
|
|
186
|
+
getScriptPrecedence(): number[];
|
|
187
|
+
getMouseCursor(): string;
|
|
188
|
+
get tabEnabled(): boolean;
|
|
189
|
+
set tabEnabled(value: boolean);
|
|
190
|
+
get tabIndex(): number;
|
|
191
|
+
set tabIndex(value: number);
|
|
192
|
+
get isInFocus(): boolean;
|
|
193
|
+
set isInFocus(value: boolean);
|
|
194
|
+
setFocus(value: boolean, fromMouseDown?: boolean, sendSoftKeyEvent?: boolean): void;
|
|
195
|
+
/**
|
|
196
|
+
*
|
|
197
|
+
*/
|
|
198
|
+
get alignmentMode(): AlignmentMode;
|
|
199
|
+
set alignmentMode(value: AlignmentMode);
|
|
200
|
+
/**
|
|
201
|
+
* Indicates the alpha transparency value of the object specified. Valid
|
|
202
|
+
* values are 0(fully transparent) to 1(fully opaque). The default value is
|
|
203
|
+
* 1. Display objects with <code>alpha</code> set to 0 <i>are</i> active,
|
|
204
|
+
* even though they are invisible.
|
|
205
|
+
*/
|
|
206
|
+
get alpha(): number;
|
|
207
|
+
set alpha(value: number);
|
|
208
|
+
/**
|
|
209
|
+
* A value from the BlendMode class that specifies which blend mode to use. A
|
|
210
|
+
* bitmap can be drawn internally in two ways. If you have a blend mode
|
|
211
|
+
* enabled or an external clipping mask, the bitmap is drawn by adding a
|
|
212
|
+
* bitmap-filled square shape to the vector render. If you attempt to set
|
|
213
|
+
* this property to an invalid value, Flash runtimes set the value to
|
|
214
|
+
* <code>BlendMode.NORMAL</code>.
|
|
215
|
+
*
|
|
216
|
+
* <p>The <code>blendMode</code> property affects each pixel of the display
|
|
217
|
+
* object. Each pixel is composed of three constituent colors(red, green,
|
|
218
|
+
* and blue), and each constituent color has a value between 0x00 and 0xFF.
|
|
219
|
+
* Flash Player or Adobe AIR compares each constituent color of one pixel in
|
|
220
|
+
* the movie clip with the corresponding color of the pixel in the
|
|
221
|
+
* background. For example, if <code>blendMode</code> is set to
|
|
222
|
+
* <code>BlendMode.LIGHTEN</code>, Flash Player or Adobe AIR compares the red
|
|
223
|
+
* value of the display object with the red value of the background, and uses
|
|
224
|
+
* the lighter of the two as the value for the red component of the displayed
|
|
225
|
+
* color.</p>
|
|
226
|
+
*
|
|
227
|
+
* <p>The following table describes the <code>blendMode</code> settings. The
|
|
228
|
+
* BlendMode class defines string values you can use. The illustrations in
|
|
229
|
+
* the table show <code>blendMode</code> values applied to a circular display
|
|
230
|
+
* object(2) superimposed on another display object(1).</p>
|
|
231
|
+
*/
|
|
232
|
+
_blendMode: BlendMode;
|
|
233
|
+
set blendMode(v: BlendMode);
|
|
234
|
+
get blendMode(): BlendMode;
|
|
235
|
+
/**
|
|
236
|
+
*
|
|
237
|
+
*/
|
|
238
|
+
get defaultBoundingVolume(): BoundingVolumeType;
|
|
239
|
+
set defaultBoundingVolume(value: BoundingVolumeType);
|
|
240
|
+
/**
|
|
241
|
+
* If set to <code>true</code>, NME will use the software renderer to cache
|
|
242
|
+
* an internal bitmap representation of the display object. For native targets,
|
|
243
|
+
* this is often much slower than the default hardware renderer. When you
|
|
244
|
+
* are using the Flash target, this caching may increase performance for display
|
|
245
|
+
* objects that contain complex vector content.
|
|
246
|
+
*
|
|
247
|
+
* <p>All vector data for a display object that has a cached bitmap is drawn
|
|
248
|
+
* to the bitmap instead of the main display. If
|
|
249
|
+
* <code>cacheAsBitmapMatrix</code> is null or unsupported, the bitmap is
|
|
250
|
+
* then copied to the main display as unstretched, unrotated pixels snapped
|
|
251
|
+
* to the nearest pixel boundaries. Pixels are mapped 1 to 1 with the parent
|
|
252
|
+
* object. If the bounds of the bitmap change, the bitmap is recreated
|
|
253
|
+
* instead of being stretched.</p>
|
|
254
|
+
*
|
|
255
|
+
* <p>If <code>cacheAsBitmapMatrix</code> is non-null and supported, the
|
|
256
|
+
* object is drawn to the off-screen bitmap using that matrix and the
|
|
257
|
+
* stretched and/or rotated results of that rendering are used to draw the
|
|
258
|
+
* object to the main display.</p>
|
|
259
|
+
*
|
|
260
|
+
* <p>No internal bitmap is created unless the <code>BBitmap</code>
|
|
261
|
+
* property is set to <code>true</code>.</p>
|
|
262
|
+
*
|
|
263
|
+
* <p>After you set the <code>cacheAsBitmap</code> property to
|
|
264
|
+
* <code>true</code>, the rendering does not change, however the display
|
|
265
|
+
* object performs pixel snapping automatically. The animation speed can be
|
|
266
|
+
* significantly faster depending on the complexity of the vector content.
|
|
267
|
+
* </p>
|
|
268
|
+
*
|
|
269
|
+
* <p>The <code>cacheAsBitmap</code> property is automatically set to
|
|
270
|
+
* <code>true</code> whenever you apply a filter to a display object(when
|
|
271
|
+
* its <code>filter</code> array is not empty), and if a display object has a
|
|
272
|
+
* filter applied to it, <code>cacheAsBitmap</code> is reported as
|
|
273
|
+
* <code>true</code> for that display object, even if you set the property to
|
|
274
|
+
* <code>false</code>. If you clear all filters for a display object, the
|
|
275
|
+
* <code>cacheAsBitmap</code> setting changes to what it was last set to.</p>
|
|
276
|
+
*
|
|
277
|
+
* <p>A display object does not use a bitmap even if the
|
|
278
|
+
* <code>cacheAsBitmap</code> property is set to <code>true</code> and
|
|
279
|
+
* instead renders from vector data in the following cases:</p>
|
|
280
|
+
*
|
|
281
|
+
* <ul>
|
|
282
|
+
* <li>The bitmap is too large. In AIR 1.5 and Flash Player 10, the maximum
|
|
283
|
+
* size for a bitmap image is 8,191 pixels in width or height, and the total
|
|
284
|
+
* number of pixels cannot exceed 16,777,215 pixels.(So, if a bitmap image
|
|
285
|
+
* is 8,191 pixels wide, it can only be 2,048 pixels high.) In Flash Player 9
|
|
286
|
+
* and earlier, the limitation is is 2880 pixels in height and 2,880 pixels
|
|
287
|
+
* in width.</li>
|
|
288
|
+
* <li>The bitmap fails to allocate(out of memory error). </li>
|
|
289
|
+
* </ul>
|
|
290
|
+
*
|
|
291
|
+
* <p>The <code>cacheAsBitmap</code> property is best used with movie clips
|
|
292
|
+
* that have mostly static content and that do not scale and rotate
|
|
293
|
+
* frequently. With such movie clips, <code>cacheAsBitmap</code> can lead to
|
|
294
|
+
* performance increases when the movie clip is translated(when its <i>x</i>
|
|
295
|
+
* and <i>y</i> position is changed).</p>
|
|
296
|
+
*/
|
|
297
|
+
private _cacheAsBitmap;
|
|
298
|
+
get cacheAsBitmap(): boolean;
|
|
299
|
+
set cacheAsBitmap(value: boolean);
|
|
300
|
+
/**
|
|
301
|
+
*
|
|
302
|
+
*/
|
|
303
|
+
castsShadows: boolean;
|
|
304
|
+
/**
|
|
305
|
+
* Defines the rotation of the 3d object as a <code>Vector3D</code>
|
|
306
|
+
* object containing euler angles for rotation around x, y and z axis.
|
|
307
|
+
*/
|
|
308
|
+
get eulers(): Vector3D;
|
|
309
|
+
set eulers(value: Vector3D);
|
|
310
|
+
/**
|
|
311
|
+
* An object that can contain any extra data.
|
|
312
|
+
*/
|
|
313
|
+
extra: Object;
|
|
314
|
+
/**
|
|
315
|
+
* An indexed array that contains each filter object currently associated
|
|
316
|
+
* with the display object. The flash.filters package contains several
|
|
317
|
+
* classes that define specific filters you can use.
|
|
318
|
+
*
|
|
319
|
+
* <p>Filters can be applied in Flash Professional at design time, or at run
|
|
320
|
+
* time by using ActionScript code. To apply a filter by using ActionScript,
|
|
321
|
+
* you must make a temporary copy of the entire <code>filters</code> array,
|
|
322
|
+
* modify the temporary array, then assign the value of the temporary array
|
|
323
|
+
* back to the <code>filters</code> array. You cannot directly add a new
|
|
324
|
+
* filter object to the <code>filters</code> array.</p>
|
|
325
|
+
*
|
|
326
|
+
* <p>To add a filter by using ActionScript, perform the following steps
|
|
327
|
+
* (assume that the target display object is named
|
|
328
|
+
* <code>myDisplayObject</code>):</p>
|
|
329
|
+
*
|
|
330
|
+
* <ol>
|
|
331
|
+
* <li>Create a new filter object by using the constructor method of your
|
|
332
|
+
* chosen filter class.</li>
|
|
333
|
+
* <li>Assign the value of the <code>myDisplayObject.filters</code> array
|
|
334
|
+
* to a temporary array, such as one named <code>myFilters</code>.</li>
|
|
335
|
+
* <li>Add the new filter object to the <code>myFilters</code> temporary
|
|
336
|
+
* array.</li>
|
|
337
|
+
* <li>Assign the value of the temporary array to the
|
|
338
|
+
* <code>myDisplayObject.filters</code> array.</li>
|
|
339
|
+
* </ol>
|
|
340
|
+
*
|
|
341
|
+
* <p>If the <code>filters</code> array is undefined, you do not need to use
|
|
342
|
+
* a temporary array. Instead, you can directly assign an array literal that
|
|
343
|
+
* contains one or more filter objects that you create. The first example in
|
|
344
|
+
* the Examples section adds a drop shadow filter by using code that handles
|
|
345
|
+
* both defined and undefined <code>filters</code> arrays.</p>
|
|
346
|
+
*
|
|
347
|
+
* <p>To modify an existing filter object, you must use the technique of
|
|
348
|
+
* modifying a copy of the <code>filters</code> array:</p>
|
|
349
|
+
*
|
|
350
|
+
* <ol>
|
|
351
|
+
* <li>Assign the value of the <code>filters</code> array to a temporary
|
|
352
|
+
* array, such as one named <code>myFilters</code>.</li>
|
|
353
|
+
* <li>Modify the property by using the temporary array,
|
|
354
|
+
* <code>myFilters</code>. For example, to set the quality property of the
|
|
355
|
+
* first filter in the array, you could use the following code:
|
|
356
|
+
* <code>myFilters[0].quality = 1;</code></li>
|
|
357
|
+
* <li>Assign the value of the temporary array to the <code>filters</code>
|
|
358
|
+
* array.</li>
|
|
359
|
+
* </ol>
|
|
360
|
+
*
|
|
361
|
+
* <p>At load time, if a display object has an associated filter, it is
|
|
362
|
+
* marked to cache itself as a transparent bitmap. From this point forward,
|
|
363
|
+
* as long as the display object has a valid filter list, the player caches
|
|
364
|
+
* the display object as a bitmap. This source bitmap is used as a source
|
|
365
|
+
* image for the filter effects. Each display object usually has two bitmaps:
|
|
366
|
+
* one with the original unfiltered source display object and another for the
|
|
367
|
+
* final image after filtering. The final image is used when rendering. As
|
|
368
|
+
* long as the display object does not change, the final image does not need
|
|
369
|
+
* updating.</p>
|
|
370
|
+
*
|
|
371
|
+
* <p>The flash.filters package includes classes for filters. For example, to
|
|
372
|
+
* create a DropShadow filter, you would write:</p>
|
|
373
|
+
*
|
|
374
|
+
* @throws ArgumentError When <code>filters</code> includes a ShaderFilter
|
|
375
|
+
* and the shader output type is not compatible with
|
|
376
|
+
* this operation(the shader must specify a
|
|
377
|
+
* <code>pixel4</code> output).
|
|
378
|
+
* @throws ArgumentError When <code>filters</code> includes a ShaderFilter
|
|
379
|
+
* and the shader doesn't specify any image input or
|
|
380
|
+
* the first input is not an <code>image4</code> input.
|
|
381
|
+
* @throws ArgumentError When <code>filters</code> includes a ShaderFilter
|
|
382
|
+
* and the shader specifies an image input that isn't
|
|
383
|
+
* provided.
|
|
384
|
+
* @throws ArgumentError When <code>filters</code> includes a ShaderFilter, a
|
|
385
|
+
* ByteArray or Vector.<Number> instance as a shader
|
|
386
|
+
* input, and the <code>width</code> and
|
|
387
|
+
* <code>height</code> properties aren't specified for
|
|
388
|
+
* the ShaderInput object, or the specified values
|
|
389
|
+
* don't match the amount of data in the input data.
|
|
390
|
+
* See the <code>ShaderInput.input</code> property for
|
|
391
|
+
* more information.
|
|
392
|
+
*/
|
|
393
|
+
private _filters;
|
|
394
|
+
set filters(v: Array<IFilter>);
|
|
395
|
+
get filters(): Array<IFilter>;
|
|
396
|
+
updateFilters(_newFilters: IFilter[]): void;
|
|
397
|
+
/**
|
|
398
|
+
* Indicates the instance container index of the DisplayObject. The object can be
|
|
399
|
+
* identified in the child list of its parent display object container by
|
|
400
|
+
* calling the <code>getChildByIndex()</code> method of the display object
|
|
401
|
+
* container.
|
|
402
|
+
*
|
|
403
|
+
* <p>If the DisplayObject has no parent container, index defaults to 0.</p>
|
|
404
|
+
*/
|
|
405
|
+
get index(): number;
|
|
406
|
+
/**
|
|
407
|
+
* Returns a LoaderInfo object containing information about loading the file
|
|
408
|
+
* to which this display object belongs. The <code>loaderInfo</code> property
|
|
409
|
+
* is defined only for the root display object of a SWF file or for a loaded
|
|
410
|
+
* Bitmap(not for a Bitmap that is drawn with ActionScript). To find the
|
|
411
|
+
* <code>loaderInfo</code> object associated with the SWF file that contains
|
|
412
|
+
* a display object named <code>myDisplayObject</code>, use
|
|
413
|
+
* <code>myDisplayObject.root.loaderInfo</code>.
|
|
414
|
+
*
|
|
415
|
+
* <p>A large SWF file can monitor its download by calling
|
|
416
|
+
* <code>this.root.loaderInfo.addEventListener(Event.COMPLETE,
|
|
417
|
+
* func)</code>.</p>
|
|
418
|
+
*/
|
|
419
|
+
get loader(): Loader;
|
|
420
|
+
/**
|
|
421
|
+
* The calling display object is masked by the specified <code>mask</code>
|
|
422
|
+
* object. To ensure that masking works when the Stage is scaled, the
|
|
423
|
+
* <code>mask</code> display object must be in an active part of the display
|
|
424
|
+
* list. The <code>mask</code> object itself is not drawn. Set
|
|
425
|
+
* <code>mask</code> to <code>null</code> to remove the mask.
|
|
426
|
+
*
|
|
427
|
+
* <p>To be able to scale a mask object, it must be on the display list. To
|
|
428
|
+
* be able to drag a mask Sprite object(by calling its
|
|
429
|
+
* <code>startDrag()</code> method), it must be on the display list. To call
|
|
430
|
+
* the <code>startDrag()</code> method for a mask sprite based on a
|
|
431
|
+
* <code>mouseDown</code> event being dispatched by the sprite, set the
|
|
432
|
+
* sprite's <code>buttonMode</code> property to <code>true</code>.</p>
|
|
433
|
+
*
|
|
434
|
+
* <p>When display objects are cached by setting the
|
|
435
|
+
* <code>cacheAsBitmap</code> property to <code>true</code> an the
|
|
436
|
+
* <code>cacheAsBitmapMatrix</code> property to a Matrix object, both the
|
|
437
|
+
* mask and the display object being masked must be part of the same cached
|
|
438
|
+
* bitmap. Thus, if the display object is cached, then the mask must be a
|
|
439
|
+
* child of the display object. If an ancestor of the display object on the
|
|
440
|
+
* display list is cached, then the mask must be a child of that ancestor or
|
|
441
|
+
* one of its descendents. If more than one ancestor of the masked object is
|
|
442
|
+
* cached, then the mask must be a descendent of the cached container closest
|
|
443
|
+
* to the masked object in the display list.</p>
|
|
444
|
+
*
|
|
445
|
+
* <p><b>Note:</b> A single <code>mask</code> object cannot be used to mask
|
|
446
|
+
* more than one calling display object. When the <code>mask</code> is
|
|
447
|
+
* assigned to a second display object, it is removed as the mask of the
|
|
448
|
+
* first object, and that object's <code>mask</code> property becomes
|
|
449
|
+
* <code>null</code>.</p>
|
|
450
|
+
*/
|
|
451
|
+
get mask(): DisplayObject | undefined;
|
|
452
|
+
set mask(value: DisplayObject | undefined);
|
|
453
|
+
get maskMode(): boolean;
|
|
454
|
+
set maskMode(value: boolean);
|
|
455
|
+
get pickObject(): DisplayObjectContainer;
|
|
456
|
+
set pickObject(value: DisplayObjectContainer);
|
|
457
|
+
/**
|
|
458
|
+
* Specifies whether this object receives mouse, or other user input,
|
|
459
|
+
* messages. The default value is <code>true</code>, which means that by
|
|
460
|
+
* default any InteractiveObject instance that is on the display list
|
|
461
|
+
* receives mouse events or other user input events. If
|
|
462
|
+
* <code>mouseEnabled</code> is set to <code>false</code>, the instance does
|
|
463
|
+
* not receive any mouse events(or other user input events like keyboard
|
|
464
|
+
* events). Any children of this instance on the display list are not
|
|
465
|
+
* affected. To change the <code>mouseEnabled</code> behavior for all
|
|
466
|
+
* children of an object on the display list, use
|
|
467
|
+
* <code>flash.display.DisplayObjectContainer.mouseChildren</code>.
|
|
468
|
+
*
|
|
469
|
+
* <p> No event is dispatched by setting this property. You must use the
|
|
470
|
+
* <code>addEventListener()</code> method to create interactive
|
|
471
|
+
* functionality.</p>
|
|
472
|
+
*/
|
|
473
|
+
get mouseEnabled(): boolean;
|
|
474
|
+
set mouseEnabled(value: boolean);
|
|
475
|
+
/**
|
|
476
|
+
* Indicates the x coordinate of the mouse or user input device position, in
|
|
477
|
+
* pixels.
|
|
478
|
+
*
|
|
479
|
+
* <p><b>Note</b>: For a DisplayObject that has been rotated, the returned x
|
|
480
|
+
* coordinate will reflect the non-rotated object.</p>
|
|
481
|
+
*/
|
|
482
|
+
get mouseX(): number;
|
|
483
|
+
/**
|
|
484
|
+
* Indicates the y coordinate of the mouse or user input device position, in
|
|
485
|
+
* pixels.
|
|
486
|
+
*
|
|
487
|
+
* <p><b>Note</b>: For a DisplayObject that has been rotated, the returned y
|
|
488
|
+
* coordinate will reflect the non-rotated object.</p>
|
|
489
|
+
*/
|
|
490
|
+
get mouseY(): number;
|
|
491
|
+
/**
|
|
492
|
+
* Indicates the instance name of the DisplayObject. The object can be
|
|
493
|
+
* identified in the child list of its parent display object container by
|
|
494
|
+
* calling the <code>getChildByName()</code> method of the display object
|
|
495
|
+
* container.
|
|
496
|
+
*
|
|
497
|
+
* @throws IllegalOperationError If you are attempting to set this property
|
|
498
|
+
* on an object that was placed on the timeline
|
|
499
|
+
* in the Flash authoring tool.
|
|
500
|
+
*/
|
|
501
|
+
get name(): string;
|
|
502
|
+
set name(value: string);
|
|
503
|
+
/**
|
|
504
|
+
*
|
|
505
|
+
*/
|
|
506
|
+
orientationMode: OrientationMode;
|
|
507
|
+
/**
|
|
508
|
+
* Indicates the DisplayObjectContainer object that contains this display
|
|
509
|
+
* object. Use the <code>parent</code> property to specify a relative path to
|
|
510
|
+
* display objects that are above the current display object in the display
|
|
511
|
+
* list hierarchy.
|
|
512
|
+
*
|
|
513
|
+
* <p>You can use <code>parent</code> to move up multiple levels in the
|
|
514
|
+
* display list as in the following:</p>
|
|
515
|
+
*
|
|
516
|
+
* @throws SecurityError The parent display object belongs to a security
|
|
517
|
+
* sandbox to which you do not have access. You can
|
|
518
|
+
* avoid this situation by having the parent movie call
|
|
519
|
+
* the <code>Security.allowDomain()</code> method.
|
|
520
|
+
*/
|
|
521
|
+
get parent(): DisplayObjectContainer;
|
|
522
|
+
/**
|
|
523
|
+
* Defines the local point around which the object rotates.
|
|
524
|
+
*/
|
|
525
|
+
get registrationPoint(): Vector3D;
|
|
526
|
+
set registrationPoint(value: Vector3D);
|
|
527
|
+
/**
|
|
528
|
+
* Defines the local scale.
|
|
529
|
+
*/
|
|
530
|
+
get registrationScale(): Vector3D;
|
|
531
|
+
set registrationScale(value: Vector3D);
|
|
532
|
+
/**
|
|
533
|
+
* For a display object in a loaded SWF file, the <code>root</code> property
|
|
534
|
+
* is the top-most display object in the portion of the display list's tree
|
|
535
|
+
* structure represented by that SWF file. For a Bitmap object representing a
|
|
536
|
+
* loaded image file, the <code>root</code> property is the Bitmap object
|
|
537
|
+
* itself. For the instance of the main class of the first SWF file loaded,
|
|
538
|
+
* the <code>root</code> property is the display object itself. The
|
|
539
|
+
* <code>root</code> property of the Scene object is the Scene object itself.
|
|
540
|
+
* The <code>root</code> property is set to <code>null</code> for any display
|
|
541
|
+
* object that has not been added to the display list, unless it has been
|
|
542
|
+
* added to a display object container that is off the display list but that
|
|
543
|
+
* is a child of the top-most display object in a loaded SWF file.
|
|
544
|
+
*
|
|
545
|
+
* <p>For example, if you create a new Sprite object by calling the
|
|
546
|
+
* <code>Sprite()</code> constructor method, its <code>root</code> property
|
|
547
|
+
* is <code>null</code> until you add it to the display list(or to a display
|
|
548
|
+
* object container that is off the display list but that is a child of the
|
|
549
|
+
* top-most display object in a SWF file).</p>
|
|
550
|
+
*
|
|
551
|
+
* <p>For a loaded SWF file, even though the Loader object used to load the
|
|
552
|
+
* file may not be on the display list, the top-most display object in the
|
|
553
|
+
* SWF file has its <code>root</code> property set to itself. The Loader
|
|
554
|
+
* object does not have its <code>root</code> property set until it is added
|
|
555
|
+
* as a child of a display object for which the <code>root</code> property is
|
|
556
|
+
* set.</p>
|
|
557
|
+
*/
|
|
558
|
+
get root(): DisplayObjectContainer;
|
|
559
|
+
/**
|
|
560
|
+
* Indicates the rotation of the DisplayObject instance, in degrees, from its
|
|
561
|
+
* original orientation. Values from 0 to 180 represent clockwise rotation;
|
|
562
|
+
* values from 0 to -180 represent counterclockwise rotation. Values outside
|
|
563
|
+
* this range are added to or subtracted from 360 to obtain a value within
|
|
564
|
+
* the range. For example, the statement <code>my_video.rotation = 450</code>
|
|
565
|
+
* is the same as <code> my_video.rotation = 90</code>.
|
|
566
|
+
*/
|
|
567
|
+
rotation: number;
|
|
568
|
+
/**
|
|
569
|
+
* Indicates the x-axis rotation of the DisplayObject instance, in degrees,
|
|
570
|
+
* from its original orientation relative to the 3D parent container. Values
|
|
571
|
+
* from 0 to 180 represent clockwise rotation; values from 0 to -180
|
|
572
|
+
* represent counterclockwise rotation. Values outside this range are added
|
|
573
|
+
* to or subtracted from 360 to obtain a value within the range.
|
|
574
|
+
*/
|
|
575
|
+
get rotationX(): number;
|
|
576
|
+
set rotationX(val: number);
|
|
577
|
+
/**
|
|
578
|
+
* Indicates the y-axis rotation of the DisplayObject instance, in degrees,
|
|
579
|
+
* from its original orientation relative to the 3D parent container. Values
|
|
580
|
+
* from 0 to 180 represent clockwise rotation; values from 0 to -180
|
|
581
|
+
* represent counterclockwise rotation. Values outside this range are added
|
|
582
|
+
* to or subtracted from 360 to obtain a value within the range.
|
|
583
|
+
*/
|
|
584
|
+
get rotationY(): number;
|
|
585
|
+
set rotationY(val: number);
|
|
586
|
+
/**
|
|
587
|
+
* Indicates the z-axis rotation of the DisplayObject instance, in degrees,
|
|
588
|
+
* from its original orientation relative to the 3D parent container. Values
|
|
589
|
+
* from 0 to 180 represent clockwise rotation; values from 0 to -180
|
|
590
|
+
* represent counterclockwise rotation. Values outside this range are added
|
|
591
|
+
* to or subtracted from 360 to obtain a value within the range.
|
|
592
|
+
*/
|
|
593
|
+
get rotationZ(): number;
|
|
594
|
+
set rotationZ(val: number);
|
|
595
|
+
/**
|
|
596
|
+
* The current scaling grid that is in effect. If set to <code>null</code>,
|
|
597
|
+
* the entire display object is scaled normally when any scale transformation
|
|
598
|
+
* is applied.
|
|
599
|
+
*
|
|
600
|
+
* <p>When you define the <code>scale9Grid</code> property, the display
|
|
601
|
+
* object is divided into a grid with nine regions based on the
|
|
602
|
+
* <code>scale9Grid</code> rectangle, which defines the center region of the
|
|
603
|
+
* grid. The eight other regions of the grid are the following areas: </p>
|
|
604
|
+
*
|
|
605
|
+
* <ul>
|
|
606
|
+
* <li>The upper-left corner outside of the rectangle</li>
|
|
607
|
+
* <li>The area above the rectangle </li>
|
|
608
|
+
* <li>The upper-right corner outside of the rectangle</li>
|
|
609
|
+
* <li>The area to the left of the rectangle</li>
|
|
610
|
+
* <li>The area to the right of the rectangle</li>
|
|
611
|
+
* <li>The lower-left corner outside of the rectangle</li>
|
|
612
|
+
* <li>The area below the rectangle</li>
|
|
613
|
+
* <li>The lower-right corner outside of the rectangle</li>
|
|
614
|
+
* </ul>
|
|
615
|
+
*
|
|
616
|
+
* <p>You can think of the eight regions outside of the center(defined by
|
|
617
|
+
* the rectangle) as being like a picture frame that has special rules
|
|
618
|
+
* applied to it when scaled.</p>
|
|
619
|
+
*
|
|
620
|
+
* <p>When the <code>scale9Grid</code> property is set and a display object
|
|
621
|
+
* is scaled, all text and gradients are scaled normally; however, for other
|
|
622
|
+
* types of objects the following rules apply:</p>
|
|
623
|
+
*
|
|
624
|
+
* <ul>
|
|
625
|
+
* <li>Content in the center region is scaled normally. </li>
|
|
626
|
+
* <li>Content in the corners is not scaled. </li>
|
|
627
|
+
* <li>Content in the top and bottom regions is scaled horizontally only.
|
|
628
|
+
* Content in the left and right regions is scaled vertically only.</li>
|
|
629
|
+
* <li>All fills(including bitmaps, video, and gradients) are stretched to
|
|
630
|
+
* fit their shapes.</li>
|
|
631
|
+
* </ul>
|
|
632
|
+
*
|
|
633
|
+
* <p>If a display object is rotated, all subsequent scaling is normal(and
|
|
634
|
+
* the <code>scale9Grid</code> property is ignored).</p>
|
|
635
|
+
*
|
|
636
|
+
* <p>For example, consider the following display object and a rectangle that
|
|
637
|
+
* is applied as the display object's <code>scale9Grid</code>:</p>
|
|
638
|
+
*
|
|
639
|
+
* <p>A common use for setting <code>scale9Grid</code> is to set up a display
|
|
640
|
+
* object to be used as a component, in which edge regions retain the same
|
|
641
|
+
* width when the component is scaled.</p>
|
|
642
|
+
*
|
|
643
|
+
* @throws ArgumentError If you pass an invalid argument to the method.
|
|
644
|
+
*/
|
|
645
|
+
get scale9Grid(): Rectangle;
|
|
646
|
+
set scale9Grid(value: Rectangle);
|
|
647
|
+
/**
|
|
648
|
+
* Indicates the horizontal scale(percentage) of the object as applied from
|
|
649
|
+
* the registration point. The default registration point is(0,0). 1.0
|
|
650
|
+
* equals 100% scale.
|
|
651
|
+
*
|
|
652
|
+
* <p>Scaling the local coordinate system changes the <code>x</code> and
|
|
653
|
+
* <code>y</code> property values, which are defined in whole pixels. </p>
|
|
654
|
+
*/
|
|
655
|
+
get scaleX(): number;
|
|
656
|
+
set scaleX(val: number);
|
|
657
|
+
/**
|
|
658
|
+
* Indicates the vertical scale(percentage) of an object as applied from the
|
|
659
|
+
* registration point of the object. The default registration point is(0,0).
|
|
660
|
+
* 1.0 is 100% scale.
|
|
661
|
+
*
|
|
662
|
+
* <p>Scaling the local coordinate system changes the <code>x</code> and
|
|
663
|
+
* <code>y</code> property values, which are defined in whole pixels. </p>
|
|
664
|
+
*/
|
|
665
|
+
get scaleY(): number;
|
|
666
|
+
set scaleY(val: number);
|
|
667
|
+
/**
|
|
668
|
+
* Indicates the depth scale(percentage) of an object as applied from the
|
|
669
|
+
* registration point of the object. The default registration point is(0,0).
|
|
670
|
+
* 1.0 is 100% scale.
|
|
671
|
+
*
|
|
672
|
+
* <p>Scaling the local coordinate system changes the <code>x</code>,
|
|
673
|
+
* <code>y</code> and <code>z</code> property values, which are defined in
|
|
674
|
+
* whole pixels. </p>
|
|
675
|
+
*/
|
|
676
|
+
get scaleZ(): number;
|
|
677
|
+
set scaleZ(val: number);
|
|
678
|
+
/**
|
|
679
|
+
* Indicates the horizontal skew(angle) of the object as applied from
|
|
680
|
+
* the registration point. The default registration point is(0,0).
|
|
681
|
+
*/
|
|
682
|
+
get skewX(): number;
|
|
683
|
+
set skewX(val: number);
|
|
684
|
+
/**
|
|
685
|
+
* Indicates the vertical skew(angle) of an object as applied from the
|
|
686
|
+
* registration point of the object. The default registration point is(0,0).
|
|
687
|
+
*/
|
|
688
|
+
get skewY(): number;
|
|
689
|
+
set skewY(val: number);
|
|
690
|
+
/**
|
|
691
|
+
* Indicates the depth skew(angle) of an object as applied from the
|
|
692
|
+
* registration point of the object. The default registration point is(0,0).
|
|
693
|
+
*/
|
|
694
|
+
get skewZ(): number;
|
|
695
|
+
set skewZ(val: number);
|
|
696
|
+
/**
|
|
697
|
+
* The scroll rectangle bounds of the display object. The display object is
|
|
698
|
+
* cropped to the size defined by the rectangle, and it scrolls within the
|
|
699
|
+
* rectangle when you change the <code>x</code> and <code>y</code> properties
|
|
700
|
+
* of the <code>scrollRect</code> object.
|
|
701
|
+
*
|
|
702
|
+
* <p>The properties of the <code>scrollRect</code> Rectangle object use the
|
|
703
|
+
* display object's coordinate space and are scaled just like the overall
|
|
704
|
+
* display object. The corner bounds of the cropped window on the scrolling
|
|
705
|
+
* display object are the origin of the display object(0,0) and the point
|
|
706
|
+
* defined by the width and height of the rectangle. They are not centered
|
|
707
|
+
* around the origin, but use the origin to define the upper-left corner of
|
|
708
|
+
* the area. A scrolled display object always scrolls in whole pixel
|
|
709
|
+
* increments. </p>
|
|
710
|
+
*
|
|
711
|
+
* <p>You can scroll an object left and right by setting the <code>x</code>
|
|
712
|
+
* property of the <code>scrollRect</code> Rectangle object. You can scroll
|
|
713
|
+
* an object up and down by setting the <code>y</code> property of the
|
|
714
|
+
* <code>scrollRect</code> Rectangle object. If the display object is rotated
|
|
715
|
+
* 90° and you scroll it left and right, the display object actually scrolls
|
|
716
|
+
* up and down.</p>
|
|
717
|
+
*/
|
|
718
|
+
get scrollRect(): Rectangle;
|
|
719
|
+
set scrollRect(value: Rectangle);
|
|
720
|
+
/**
|
|
721
|
+
*
|
|
722
|
+
*/
|
|
723
|
+
get material(): IMaterial;
|
|
724
|
+
set material(value: IMaterial);
|
|
725
|
+
/**
|
|
726
|
+
*
|
|
727
|
+
*/
|
|
728
|
+
get style(): Style;
|
|
729
|
+
set style(value: Style);
|
|
730
|
+
/**
|
|
731
|
+
*
|
|
732
|
+
*/
|
|
733
|
+
get boundsVisible(): boolean;
|
|
734
|
+
set boundsVisible(value: boolean);
|
|
735
|
+
getScrollRectPrimitive(): IContainer;
|
|
736
|
+
getBoundsPrimitive(picker: BoundsPicker): IContainer;
|
|
737
|
+
/**
|
|
738
|
+
* An object with properties pertaining to a display object's matrix, color
|
|
739
|
+
* transform, and pixel bounds. The specific properties - matrix,
|
|
740
|
+
* colorTransform, and three read-only properties
|
|
741
|
+
* (<code>concatenatedMatrix</code>, <code>concatenatedColorTransform</code>,
|
|
742
|
+
* and <code>pixelBounds</code>) - are described in the entry for the
|
|
743
|
+
* Transform class.
|
|
744
|
+
*
|
|
745
|
+
* <p>Each of the transform object's properties is itself an object. This
|
|
746
|
+
* concept is important because the only way to set new values for the matrix
|
|
747
|
+
* or colorTransform objects is to create a new object and copy that object
|
|
748
|
+
* into the transform.matrix or transform.colorTransform property.</p>
|
|
749
|
+
*
|
|
750
|
+
* <p>For example, to increase the <code>tx</code> value of a display
|
|
751
|
+
* object's matrix, you must make a copy of the entire matrix object, then
|
|
752
|
+
* copy the new object into the matrix property of the transform object:</p>
|
|
753
|
+
* <pre xml:space="preserve"><code> public myMatrix:Matrix =
|
|
754
|
+
* myDisplayObject.transform.matrix; myMatrix.tx += 10;
|
|
755
|
+
* myDisplayObject.transform.matrix = myMatrix; </code></pre>
|
|
756
|
+
*
|
|
757
|
+
* <p>You cannot directly set the <code>tx</code> property. The following
|
|
758
|
+
* code has no effect on <code>myDisplayObject</code>: </p>
|
|
759
|
+
* <pre xml:space="preserve"><code> myDisplayObject.transform.matrix.tx +=
|
|
760
|
+
* 10; </code></pre>
|
|
761
|
+
*
|
|
762
|
+
* <p>You can also copy an entire transform object and assign it to another
|
|
763
|
+
* display object's transform property. For example, the following code
|
|
764
|
+
* copies the entire transform object from <code>myOldDisplayObj</code> to
|
|
765
|
+
* <code>myNewDisplayObj</code>:</p>
|
|
766
|
+
* <code>myNewDisplayObj.transform = myOldDisplayObj.transform;</code>
|
|
767
|
+
*
|
|
768
|
+
* <p>The resulting display object, <code>myNewDisplayObj</code>, now has the
|
|
769
|
+
* same values for its matrix, color transform, and pixel bounds as the old
|
|
770
|
+
* display object, <code>myOldDisplayObj</code>.</p>
|
|
771
|
+
*
|
|
772
|
+
* <p>Note that AIR for TV devices use hardware acceleration, if it is
|
|
773
|
+
* available, for color transforms.</p>
|
|
774
|
+
*/
|
|
775
|
+
get transform(): Transform;
|
|
776
|
+
/**
|
|
777
|
+
* Whether or not the display object is visible. Display objects that are not
|
|
778
|
+
* visible are disabled. For example, if <code>visible=false</code> for an
|
|
779
|
+
* InteractiveObject instance, it cannot be clicked.
|
|
780
|
+
*/
|
|
781
|
+
get visible(): boolean;
|
|
782
|
+
set visible(value: boolean);
|
|
783
|
+
/**
|
|
784
|
+
* Update mask from timeline and take account that can be a scriptMask
|
|
785
|
+
*
|
|
786
|
+
* @param masks Masks from timeline
|
|
787
|
+
*/
|
|
788
|
+
set timelineMasks(masks: DisplayObject[] | undefined);
|
|
789
|
+
get timelineMasks(): DisplayObject[] | undefined;
|
|
790
|
+
/**
|
|
791
|
+
* Determines whether or not the children of the object are mouse, or user
|
|
792
|
+
* input device, enabled. If an object is enabled, a user can interact with
|
|
793
|
+
* it by using a mouse or user input device. The default is
|
|
794
|
+
* <code>true</code>.
|
|
795
|
+
*
|
|
796
|
+
* <p>This property is useful when you create a button with an instance of
|
|
797
|
+
* the Sprite class(instead of using the SimpleButton class). When you use a
|
|
798
|
+
* Sprite instance to create a button, you can choose to decorate the button
|
|
799
|
+
* by using the <code>addChild()</code> method to add additional Sprite
|
|
800
|
+
* instances. This process can cause unexpected behavior with mouse events
|
|
801
|
+
* because the Sprite instances you add as children can become the target
|
|
802
|
+
* object of a mouse event when you expect the parent instance to be the
|
|
803
|
+
* target object. To ensure that the parent instance serves as the target
|
|
804
|
+
* objects for mouse events, you can set the <code>mouseChildren</code>
|
|
805
|
+
* property of the parent instance to <code>false</code>.</p>
|
|
806
|
+
*
|
|
807
|
+
* <p> No event is dispatched by setting this property. You must use the
|
|
808
|
+
* <code>addEventListener()</code> method to create interactive
|
|
809
|
+
* functionality.</p>
|
|
810
|
+
*/
|
|
811
|
+
get mouseChildren(): boolean;
|
|
812
|
+
set mouseChildren(value: boolean);
|
|
813
|
+
/**
|
|
814
|
+
* Indicates the <i>x</i> coordinate of the DisplayObject instance relative
|
|
815
|
+
* to the local coordinates of the parent DisplayObjectContainer. If the
|
|
816
|
+
* object is inside a DisplayObjectContainer that has transformations, it is
|
|
817
|
+
* in the local coordinate system of the enclosing DisplayObjectContainer.
|
|
818
|
+
* Thus, for a DisplayObjectContainer rotated 90° counterclockwise, the
|
|
819
|
+
* DisplayObjectContainer's children inherit a coordinate system that is
|
|
820
|
+
* rotated 90° counterclockwise. The object's coordinates refer to the
|
|
821
|
+
* registration point position.
|
|
822
|
+
*/
|
|
823
|
+
get x(): number;
|
|
824
|
+
set x(val: number);
|
|
825
|
+
/**
|
|
826
|
+
* Indicates the <i>y</i> coordinate of the DisplayObject instance relative
|
|
827
|
+
* to the local coordinates of the parent DisplayObjectContainer. If the
|
|
828
|
+
* object is inside a DisplayObjectContainer that has transformations, it is
|
|
829
|
+
* in the local coordinate system of the enclosing DisplayObjectContainer.
|
|
830
|
+
* Thus, for a DisplayObjectContainer rotated 90° counterclockwise, the
|
|
831
|
+
* DisplayObjectContainer's children inherit a coordinate system that is
|
|
832
|
+
* rotated 90° counterclockwise. The object's coordinates refer to the
|
|
833
|
+
* registration point position.
|
|
834
|
+
*/
|
|
835
|
+
get y(): number;
|
|
836
|
+
set y(val: number);
|
|
837
|
+
/**
|
|
838
|
+
* Indicates the z coordinate position along the z-axis of the DisplayObject
|
|
839
|
+
* instance relative to the 3D parent container. The z property is used for
|
|
840
|
+
* 3D coordinates, not screen or pixel coordinates.
|
|
841
|
+
*
|
|
842
|
+
* <p>When you set a <code>z</code> property for a display object to
|
|
843
|
+
* something other than the default value of <code>0</code>, a corresponding
|
|
844
|
+
* Matrix3D object is automatically created. for adjusting a display object's
|
|
845
|
+
* position and orientation in three dimensions. When working with the
|
|
846
|
+
* z-axis, the existing behavior of x and y properties changes from screen or
|
|
847
|
+
* pixel coordinates to positions relative to the 3D parent container.</p>
|
|
848
|
+
*
|
|
849
|
+
* <p>For example, a child of the <code>_root</code> at position x = 100, y =
|
|
850
|
+
* 100, z = 200 is not drawn at pixel location(100,100). The child is drawn
|
|
851
|
+
* wherever the 3D projection calculation puts it. The calculation is:</p>
|
|
852
|
+
*
|
|
853
|
+
* <p><code>(x~~cameraFocalLength/cameraRelativeZPosition,
|
|
854
|
+
* y~~cameraFocalLength/cameraRelativeZPosition)</code></p>
|
|
855
|
+
*/
|
|
856
|
+
get z(): number;
|
|
857
|
+
set z(val: number);
|
|
858
|
+
/**
|
|
859
|
+
*
|
|
860
|
+
*/
|
|
861
|
+
zOffset: number;
|
|
862
|
+
/**
|
|
863
|
+
* Creates a new <code>DisplayObject</code> instance.
|
|
864
|
+
*/
|
|
865
|
+
constructor();
|
|
866
|
+
advanceFrame(): void;
|
|
867
|
+
getEntity(): IEntity;
|
|
868
|
+
_initNode(node: ContainerNode): void;
|
|
869
|
+
/**
|
|
870
|
+
*
|
|
871
|
+
*/
|
|
872
|
+
clone(): DisplayObject;
|
|
873
|
+
copyTo(displayObject: DisplayObject): void;
|
|
874
|
+
/**
|
|
875
|
+
*
|
|
876
|
+
*/
|
|
877
|
+
dispose(): void;
|
|
878
|
+
disposeValues(): void;
|
|
879
|
+
/**
|
|
880
|
+
* Rotates the 3d object around to face a point defined relative
|
|
881
|
+
* to the local coordinates of the parent <code>ObjectContainer3D</code>.
|
|
882
|
+
*
|
|
883
|
+
* @param scenePosition The vector defining the point to be looked at
|
|
884
|
+
* @param upAxis An optional vector used to define the desired
|
|
885
|
+
* up orientation of the 3d object after rotation has occurred
|
|
886
|
+
*/
|
|
887
|
+
lookAt(scenePosition: Vector3D, upAxis?: Vector3D): void;
|
|
888
|
+
/**
|
|
889
|
+
* Moves the local point around which the object rotates.
|
|
890
|
+
*
|
|
891
|
+
* @param dx The amount of movement along the local x axis.
|
|
892
|
+
* @param dy The amount of movement along the local y axis.
|
|
893
|
+
* @param dz The amount of movement along the local z axis.
|
|
894
|
+
*/
|
|
895
|
+
movePivot(dx: number, dy: number, dz: number): void;
|
|
896
|
+
reset(): void;
|
|
897
|
+
/**
|
|
898
|
+
* @internal
|
|
899
|
+
*/
|
|
900
|
+
_iController: ControllerBase;
|
|
901
|
+
hasDispatchedAddedToStage: boolean;
|
|
902
|
+
isOnDisplayList(): boolean;
|
|
903
|
+
/**
|
|
904
|
+
* @internal
|
|
905
|
+
*/
|
|
906
|
+
_setParent(parent: DisplayObjectContainer): void;
|
|
907
|
+
_invalidateHierarchicalProperty(propDirty: HierarchicalProperty): void;
|
|
908
|
+
/**
|
|
909
|
+
* @internal
|
|
910
|
+
*/
|
|
911
|
+
get maskId(): number;
|
|
912
|
+
protected _setScaleX(val: number): void;
|
|
913
|
+
protected _setScaleY(val: number): void;
|
|
914
|
+
protected _setScaleZ(val: number): void;
|
|
915
|
+
private _updateBoundsPrefab;
|
|
916
|
+
protected _updateMaskMode(): void;
|
|
917
|
+
_invalidateMaterial(): void;
|
|
918
|
+
private _invalidateStyle;
|
|
919
|
+
invalidateElements(): void;
|
|
920
|
+
protected _onInvalidateProperties(_event?: StyleEvent): void;
|
|
921
|
+
protected _onInvalidateImages(_event?: StyleEvent): void;
|
|
922
|
+
protected _getDefaultBoundingVolume(): BoundingVolumeType;
|
|
923
|
+
requestAbstraction(asset: IAsset): IAbstraction;
|
|
924
|
+
storeAbstraction(abstraction: IAbstraction): void;
|
|
925
|
+
getNode(container: IContainer): ContainerNode;
|
|
926
|
+
}
|
|
922
927
|
//# sourceMappingURL=DisplayObject.d.ts.map
|