@next2d/display 1.14.20
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/LICENSE +21 -0
- package/README.md +11 -0
- package/dist/BitmapData.d.ts +142 -0
- package/dist/BitmapData.js +386 -0
- package/dist/BlendMode.d.ts +204 -0
- package/dist/BlendMode.js +240 -0
- package/dist/DisplayObject.d.ts +556 -0
- package/dist/DisplayObject.js +1671 -0
- package/dist/DisplayObjectContainer.d.ts +346 -0
- package/dist/DisplayObjectContainer.js +1775 -0
- package/dist/FrameLabel.d.ts +98 -0
- package/dist/FrameLabel.js +120 -0
- package/dist/Graphics.d.ts +571 -0
- package/dist/Graphics.js +2164 -0
- package/dist/GraphicsBitmapFill.d.ts +49 -0
- package/dist/GraphicsBitmapFill.js +86 -0
- package/dist/GraphicsGradientFill.d.ts +65 -0
- package/dist/GraphicsGradientFill.js +157 -0
- package/dist/InteractiveObject.d.ts +32 -0
- package/dist/InteractiveObject.js +43 -0
- package/dist/Loader.d.ts +130 -0
- package/dist/Loader.js +318 -0
- package/dist/LoaderInfo.d.ts +120 -0
- package/dist/LoaderInfo.js +184 -0
- package/dist/LoopConfig.d.ts +108 -0
- package/dist/LoopConfig.js +156 -0
- package/dist/LoopType.d.ts +104 -0
- package/dist/LoopType.js +122 -0
- package/dist/MovieClip.d.ts +310 -0
- package/dist/MovieClip.js +940 -0
- package/dist/Shape.d.ts +164 -0
- package/dist/Shape.js +509 -0
- package/dist/Sprite.d.ts +170 -0
- package/dist/Sprite.js +280 -0
- package/dist/Stage.d.ts +164 -0
- package/dist/Stage.js +251 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.js +17 -0
- package/package.json +45 -0
|
@@ -0,0 +1,346 @@
|
|
|
1
|
+
import { InteractiveObject } from "./InteractiveObject";
|
|
2
|
+
import { DictionaryTagImpl, PlaceObjectImpl, DisplayObjectImpl, BoundsImpl, PreObjectImpl, PlayerHitObjectImpl } from "@next2d/interface";
|
|
3
|
+
import { CanvasToWebGLContext } from "@next2d/webgl";
|
|
4
|
+
/**
|
|
5
|
+
* DisplayObjectContainer クラスは、表示リストで表示オブジェクトコンテナとして機能するすべてのオブジェクトの基本クラスです。
|
|
6
|
+
* このクラス自体は、画面上でのコンテンツの描画のための API を含みません。
|
|
7
|
+
* そのため、DisplayObject クラスのカスタムサブクラスを作成する場合は、
|
|
8
|
+
* Sprite、または MovieClip など、画面上にコンテンツを描画する API を持つサブクラスの 1 つを拡張する必要があります。
|
|
9
|
+
*
|
|
10
|
+
* The DisplayObjectContainer class is the base class for all objects that can serve
|
|
11
|
+
* as display object containers on the display list.
|
|
12
|
+
* This class itself does not contain any API for drawing content on the screen.
|
|
13
|
+
* Therefore, if you want to create a custom subclass of the DisplayObject class,
|
|
14
|
+
* you need to extend one of its subclasses that has an API for drawing content on the screen,
|
|
15
|
+
* such as Sprite or MovieClip.
|
|
16
|
+
*
|
|
17
|
+
* @class
|
|
18
|
+
* @memberOf next2d.display
|
|
19
|
+
* @extends InteractiveObject
|
|
20
|
+
*/
|
|
21
|
+
export declare class DisplayObjectContainer extends InteractiveObject {
|
|
22
|
+
protected _$placeMap: Array<Array<number>> | null;
|
|
23
|
+
protected _$placeObjects: PlaceObjectImpl[] | null;
|
|
24
|
+
protected _$controller: Array<Array<number>> | null;
|
|
25
|
+
protected _$dictionary: DictionaryTagImpl[] | null;
|
|
26
|
+
protected readonly _$children: DisplayObjectImpl<any>[];
|
|
27
|
+
protected _$needsChildren: boolean;
|
|
28
|
+
protected _$mouseChildren: boolean;
|
|
29
|
+
protected _$wait: boolean;
|
|
30
|
+
protected readonly _$names: Map<string, DisplayObjectImpl<any>>;
|
|
31
|
+
/**
|
|
32
|
+
* @constructor
|
|
33
|
+
* @public
|
|
34
|
+
*/
|
|
35
|
+
constructor();
|
|
36
|
+
/**
|
|
37
|
+
* @description オブジェクトの子がマウスまたはユーザー入力デバイスに対応しているかどうかを判断します。
|
|
38
|
+
* Determine if the object's children are compatible with mouse or user input devices.
|
|
39
|
+
*
|
|
40
|
+
* @member {boolean}
|
|
41
|
+
* @public
|
|
42
|
+
*/
|
|
43
|
+
get mouseChildren(): boolean;
|
|
44
|
+
set mouseChildren(mouse_children: boolean);
|
|
45
|
+
/**
|
|
46
|
+
* @description このオブジェクトの子の数を返します。
|
|
47
|
+
* Returns the number of children of this object.
|
|
48
|
+
*
|
|
49
|
+
* @member {number}
|
|
50
|
+
* @readonly
|
|
51
|
+
* @public
|
|
52
|
+
*/
|
|
53
|
+
get numChildren(): number;
|
|
54
|
+
/**
|
|
55
|
+
* @description この DisplayObjectContainer インスタンスに子 DisplayObject インスタンスを追加します。
|
|
56
|
+
* Adds a child DisplayObject instance to this DisplayObjectContainer instance.
|
|
57
|
+
*
|
|
58
|
+
* @param {DisplayObject} child
|
|
59
|
+
* @return {DisplayObject}
|
|
60
|
+
* @method
|
|
61
|
+
* @public
|
|
62
|
+
*/
|
|
63
|
+
addChild(child: DisplayObjectImpl<any>): DisplayObjectImpl<any>;
|
|
64
|
+
/**
|
|
65
|
+
* @description この DisplayObjectContainer インスタンスに子 DisplayObject インスタンスを追加します。
|
|
66
|
+
* Adds a child DisplayObject instance to this DisplayObjectContainer instance.
|
|
67
|
+
*
|
|
68
|
+
* @param {DisplayObject} child
|
|
69
|
+
* @param {number} index
|
|
70
|
+
* @return {DisplayObject}
|
|
71
|
+
* @method
|
|
72
|
+
* @public
|
|
73
|
+
*/
|
|
74
|
+
addChildAt(child: DisplayObjectImpl<any>, index: number): DisplayObjectImpl<any>;
|
|
75
|
+
/**
|
|
76
|
+
* @description 指定された表示オブジェクトが、DisplayObjectContainer インスタンスの子であるか
|
|
77
|
+
* インスタンス自体であるかを指定します。
|
|
78
|
+
* Determines whether the specified display object is a child
|
|
79
|
+
* of the DisplayObjectContainer instance or the instance itself.
|
|
80
|
+
*
|
|
81
|
+
* @param {DisplayObject} child
|
|
82
|
+
* @return {boolean}
|
|
83
|
+
* @method
|
|
84
|
+
* @public
|
|
85
|
+
*/
|
|
86
|
+
contains(child: DisplayObjectImpl<any>): boolean;
|
|
87
|
+
/**
|
|
88
|
+
* @description 指定のインデックス位置にある子表示オブジェクトインスタンスを返します。
|
|
89
|
+
* Returns the child display object instance that exists at the specified index.
|
|
90
|
+
*
|
|
91
|
+
* @param {number} index
|
|
92
|
+
* @return {DisplayObject}
|
|
93
|
+
* @method
|
|
94
|
+
* @public
|
|
95
|
+
*/
|
|
96
|
+
getChildAt(index: number): DisplayObjectImpl<any>;
|
|
97
|
+
/**
|
|
98
|
+
* @description 指定された名前に一致する子表示オブジェクトを返します。
|
|
99
|
+
* Returns the child display object that exists with the specified name.
|
|
100
|
+
*
|
|
101
|
+
* @param {string} name
|
|
102
|
+
* @return {{DisplayObject}|null}
|
|
103
|
+
* @method
|
|
104
|
+
* @public
|
|
105
|
+
*/
|
|
106
|
+
getChildByName(name: string): DisplayObjectImpl<any> | null;
|
|
107
|
+
/**
|
|
108
|
+
* @description 子 DisplayObject インスタンスのインデックス位置を返します。
|
|
109
|
+
* Returns the index position of a child DisplayObject instance.
|
|
110
|
+
*
|
|
111
|
+
* @param {DisplayObject} child
|
|
112
|
+
* @return {number}
|
|
113
|
+
* @method
|
|
114
|
+
* @public
|
|
115
|
+
*/
|
|
116
|
+
getChildIndex(child: DisplayObjectImpl<any>): number;
|
|
117
|
+
/**
|
|
118
|
+
* @description DisplayObjectContainer インスタンスの子リストから指定の
|
|
119
|
+
* child DisplayObject インスタンスを削除します。
|
|
120
|
+
* Removes the specified child DisplayObject instance from the
|
|
121
|
+
* child list of the DisplayObjectContainer instance.
|
|
122
|
+
*
|
|
123
|
+
* @param {DisplayObject} child
|
|
124
|
+
* @return {DisplayObject}
|
|
125
|
+
* @method
|
|
126
|
+
* @public
|
|
127
|
+
*/
|
|
128
|
+
removeChild(child: DisplayObjectImpl<any>): DisplayObjectImpl<any>;
|
|
129
|
+
/**
|
|
130
|
+
* @description DisplayObjectContainer の子リストの指定された index 位置から子 DisplayObject を削除します。
|
|
131
|
+
* Removes a child DisplayObject from the specified index position
|
|
132
|
+
* in the child list of the DisplayObjectContainer.
|
|
133
|
+
*
|
|
134
|
+
* @param {number} index
|
|
135
|
+
* @return {DisplayObject}
|
|
136
|
+
* @method
|
|
137
|
+
* @public
|
|
138
|
+
*/
|
|
139
|
+
removeChildAt(index: number): DisplayObjectImpl<any>;
|
|
140
|
+
/**
|
|
141
|
+
* @description DisplayObjectContainer インスタンスの子リストから
|
|
142
|
+
* すべての child DisplayObject インスタンスを削除します。
|
|
143
|
+
* Removes all child DisplayObject instances from
|
|
144
|
+
* the child list of the DisplayObjectContainer instance.
|
|
145
|
+
*
|
|
146
|
+
* @param {number} [begin_index=0]
|
|
147
|
+
* @param {number} [end_index=0x7fffffff]
|
|
148
|
+
* @return {void}
|
|
149
|
+
* @method
|
|
150
|
+
* @public
|
|
151
|
+
*/
|
|
152
|
+
removeChildren(begin_index?: number, end_index?: number): void;
|
|
153
|
+
/**
|
|
154
|
+
* @description 表示オブジェクトコンテナの既存の子の位置を変更します。
|
|
155
|
+
* Changes the position of an existing child in the display object container.
|
|
156
|
+
*
|
|
157
|
+
* @param {DisplayObject} child
|
|
158
|
+
* @param {number} index
|
|
159
|
+
* @return {void}
|
|
160
|
+
* @method
|
|
161
|
+
* @public
|
|
162
|
+
*/
|
|
163
|
+
setChildIndex(child: DisplayObjectImpl<any>, index: number): void;
|
|
164
|
+
/**
|
|
165
|
+
* @description 指定された 2 つの子オブジェクトの z 順序(重ね順)を入れ替えます。
|
|
166
|
+
* Swaps the z-order (front-to-back order) of the two specified child objects.
|
|
167
|
+
*
|
|
168
|
+
* @param {DisplayObject} child1
|
|
169
|
+
* @param {DisplayObject} child2
|
|
170
|
+
* @return {void}
|
|
171
|
+
* @method
|
|
172
|
+
* @public
|
|
173
|
+
*/
|
|
174
|
+
swapChildren(child1: DisplayObjectImpl<any>, child2: DisplayObjectImpl<any>): void;
|
|
175
|
+
/**
|
|
176
|
+
* @description 子リスト内の指定されたインデックス位置に該当する 2 つの子オブジェクトの z 順序(重ね順)を入れ替えます。
|
|
177
|
+
* Swaps the z-order (front-to-back order) of the child objects at
|
|
178
|
+
* the two specified index positions in the child list.
|
|
179
|
+
*
|
|
180
|
+
* @param {number} index1
|
|
181
|
+
* @param {number} index2
|
|
182
|
+
* @return {void}
|
|
183
|
+
* @method
|
|
184
|
+
* @public
|
|
185
|
+
*/
|
|
186
|
+
swapChildrenAt(index1: number, index2: number): void;
|
|
187
|
+
/**
|
|
188
|
+
* @param {array} [matrix=null]
|
|
189
|
+
* @return {object}
|
|
190
|
+
* @private
|
|
191
|
+
*/
|
|
192
|
+
_$getBounds(matrix?: Float32Array | null): BoundsImpl;
|
|
193
|
+
/**
|
|
194
|
+
* @param {array} [matrix=null]
|
|
195
|
+
* @return {object}
|
|
196
|
+
* @private
|
|
197
|
+
*/
|
|
198
|
+
_$getLayerBounds(matrix?: Float32Array | null): BoundsImpl;
|
|
199
|
+
/**
|
|
200
|
+
* @return {array}
|
|
201
|
+
* @private
|
|
202
|
+
*/
|
|
203
|
+
_$getChildren(): DisplayObjectImpl<any>[];
|
|
204
|
+
/**
|
|
205
|
+
* @return void
|
|
206
|
+
* @private
|
|
207
|
+
*/
|
|
208
|
+
_$clearChildren(): void;
|
|
209
|
+
/**
|
|
210
|
+
* @param {DisplayObject} child
|
|
211
|
+
* @returns {DisplayObject}
|
|
212
|
+
* @private
|
|
213
|
+
*/
|
|
214
|
+
_$addChild(child: DisplayObjectImpl<any>): DisplayObjectImpl<any>;
|
|
215
|
+
/**
|
|
216
|
+
* @return {void}
|
|
217
|
+
* @method
|
|
218
|
+
* @private
|
|
219
|
+
*/
|
|
220
|
+
_$setParentAndStage(): void;
|
|
221
|
+
/**
|
|
222
|
+
* @return {void}
|
|
223
|
+
* @method
|
|
224
|
+
* @private
|
|
225
|
+
*/
|
|
226
|
+
_$executeAddedToStage(): void;
|
|
227
|
+
/**
|
|
228
|
+
* @param {DisplayObject} child
|
|
229
|
+
* @param {boolean} do_event
|
|
230
|
+
* @return {DisplayObject}
|
|
231
|
+
* @private
|
|
232
|
+
*/
|
|
233
|
+
_$remove(child: DisplayObjectImpl<any>, do_event?: boolean): DisplayObjectImpl<any>;
|
|
234
|
+
/**
|
|
235
|
+
* @return {void}
|
|
236
|
+
* @method
|
|
237
|
+
* @private
|
|
238
|
+
*/
|
|
239
|
+
_$executeRemovedFromStage(): void;
|
|
240
|
+
/**
|
|
241
|
+
* @return {void}
|
|
242
|
+
* @method
|
|
243
|
+
* @private
|
|
244
|
+
*/
|
|
245
|
+
_$removeParentAndStage(): void;
|
|
246
|
+
/**
|
|
247
|
+
* @return {void}
|
|
248
|
+
* @method
|
|
249
|
+
* @private
|
|
250
|
+
*/
|
|
251
|
+
_$prepareActions(): void;
|
|
252
|
+
/**
|
|
253
|
+
* @return {boolean}
|
|
254
|
+
* @method
|
|
255
|
+
* @private
|
|
256
|
+
*/
|
|
257
|
+
_$nextFrame(): boolean;
|
|
258
|
+
/**
|
|
259
|
+
* @param {CanvasToWebGLContext} context
|
|
260
|
+
* @param {Float32Array} matrix
|
|
261
|
+
* @return {void}
|
|
262
|
+
* @method
|
|
263
|
+
* @private
|
|
264
|
+
*/
|
|
265
|
+
_$clip(context: CanvasToWebGLContext, matrix: Float32Array): void;
|
|
266
|
+
/**
|
|
267
|
+
* @param {CanvasToWebGLContext} context
|
|
268
|
+
* @param {Float32Array} matrix
|
|
269
|
+
* @return {object}
|
|
270
|
+
* @private
|
|
271
|
+
*/
|
|
272
|
+
_$preDraw(context: CanvasToWebGLContext, matrix: Float32Array): PreObjectImpl | null;
|
|
273
|
+
/**
|
|
274
|
+
* @param {CanvasToWebGLContext} context
|
|
275
|
+
* @param {Float32Array} matrix
|
|
276
|
+
* @param {Float32Array} color_transform
|
|
277
|
+
* @param {object} object
|
|
278
|
+
* @return {void}
|
|
279
|
+
* @method
|
|
280
|
+
* @private
|
|
281
|
+
*/
|
|
282
|
+
_$postDraw(context: CanvasToWebGLContext, matrix: Float32Array, color_transform: Float32Array, object: PreObjectImpl): void;
|
|
283
|
+
/**
|
|
284
|
+
* @param {CanvasToWebGLContext} context
|
|
285
|
+
* @param {Float32Array} matrix
|
|
286
|
+
* @param {Float32Array} color_transform
|
|
287
|
+
* @return {void}
|
|
288
|
+
* @method
|
|
289
|
+
* @private
|
|
290
|
+
*/
|
|
291
|
+
_$draw(context: CanvasToWebGLContext, matrix: Float32Array, color_transform: Float32Array): void;
|
|
292
|
+
/**
|
|
293
|
+
* @param {CanvasRenderingContext2D} context
|
|
294
|
+
* @param {Float32Array} matrix
|
|
295
|
+
* @param {object} options
|
|
296
|
+
* @param {boolean} [mouse_children=true]
|
|
297
|
+
* @return {boolean}
|
|
298
|
+
* @method
|
|
299
|
+
* @private
|
|
300
|
+
*/
|
|
301
|
+
_$mouseHit(context: CanvasRenderingContext2D, matrix: Float32Array, options: PlayerHitObjectImpl, mouse_children?: boolean): boolean;
|
|
302
|
+
/**
|
|
303
|
+
* @param {CanvasRenderingContext2D} context
|
|
304
|
+
* @param {Float32Array} matrix
|
|
305
|
+
* @param {object} options
|
|
306
|
+
* @param {boolean} [is_clip=false]
|
|
307
|
+
* @return {boolean}
|
|
308
|
+
* @method
|
|
309
|
+
* @private
|
|
310
|
+
*/
|
|
311
|
+
_$hit(context: CanvasRenderingContext2D, matrix: Float32Array, options: PlayerHitObjectImpl, is_clip?: boolean): boolean;
|
|
312
|
+
/**
|
|
313
|
+
* @param {number} index
|
|
314
|
+
* @return {DisplayObject}
|
|
315
|
+
* @method
|
|
316
|
+
* @private
|
|
317
|
+
*/
|
|
318
|
+
_$createInstance(index: number): DisplayObjectImpl<any>;
|
|
319
|
+
/**
|
|
320
|
+
* @param {number} x
|
|
321
|
+
* @param {number} y
|
|
322
|
+
* @return {boolean}
|
|
323
|
+
* @method
|
|
324
|
+
* @private
|
|
325
|
+
*/
|
|
326
|
+
_$outCheck(x: number, y: number): boolean;
|
|
327
|
+
/**
|
|
328
|
+
* @return {void}
|
|
329
|
+
* @method
|
|
330
|
+
* @private
|
|
331
|
+
*/
|
|
332
|
+
_$createWorkerInstance(): void;
|
|
333
|
+
/**
|
|
334
|
+
* @return {object}
|
|
335
|
+
* @method
|
|
336
|
+
* @private
|
|
337
|
+
*/
|
|
338
|
+
_$postProperty(): void;
|
|
339
|
+
/**
|
|
340
|
+
* @param {array} [childrenIds=null]
|
|
341
|
+
* @return {void}
|
|
342
|
+
* @method
|
|
343
|
+
* @private
|
|
344
|
+
*/
|
|
345
|
+
_$postChildrenIds(childrenIds?: number[] | null): void;
|
|
346
|
+
}
|