@safe-engine/pixi 8.5.5 → 8.5.6
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.
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { NodeComp } from "..";
|
|
2
|
+
|
|
3
|
+
interface BaseComponentProps {
|
|
4
|
+
$ref?: object;
|
|
5
|
+
$refNode?: NodeComp<any>
|
|
6
|
+
$push?: object[];
|
|
7
|
+
node?: Partial<NodeComp>;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
interface NodeCompProps {
|
|
11
|
+
nodeName?: string
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
interface LoadingBarProps {
|
|
15
|
+
}
|
|
@@ -16,22 +16,22 @@ export class NoRenderSystem {
|
|
|
16
16
|
const container = nodeComp.instance;
|
|
17
17
|
container.eventMode = 'static';
|
|
18
18
|
if (touchComp.props.onTouchStart) {
|
|
19
|
-
container.on('
|
|
19
|
+
container.on('pointerdown', (event) => {
|
|
20
20
|
touchComp.props.onTouchStart(new Touch(event), nodeComp);
|
|
21
21
|
});
|
|
22
22
|
}
|
|
23
23
|
if (touchComp.props.onTouchMove) {
|
|
24
|
-
container.on('
|
|
24
|
+
container.on('pointermove', (event) => {
|
|
25
25
|
touchComp.props.onTouchMove(new Touch(event), nodeComp);
|
|
26
26
|
});
|
|
27
27
|
}
|
|
28
28
|
if (touchComp.props.onTouchEnd) {
|
|
29
|
-
container.on('
|
|
29
|
+
container.on('pointerup', (event) => {
|
|
30
30
|
touchComp.props.onTouchEnd(new Touch(event), nodeComp);
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
33
|
if (touchComp.props.onTouchCancel) {
|
|
34
|
-
container.on('
|
|
34
|
+
container.on('pointercancel', (event) => {
|
|
35
35
|
touchComp.props.onTouchCancel(new Touch(event), nodeComp);
|
|
36
36
|
});
|
|
37
37
|
}
|
|
@@ -41,16 +41,16 @@ export class NoRenderSystem {
|
|
|
41
41
|
const touchComp = component;
|
|
42
42
|
const container = touchComp.node.instance;
|
|
43
43
|
if (touchComp.props.onTouchStart) {
|
|
44
|
-
container.removeListener('
|
|
44
|
+
container.removeListener('pointerdown');
|
|
45
45
|
}
|
|
46
46
|
if (touchComp.props.onTouchMove) {
|
|
47
|
-
container.removeListener('
|
|
47
|
+
container.removeListener('pointermove');
|
|
48
48
|
}
|
|
49
49
|
if (touchComp.props.onTouchEnd) {
|
|
50
|
-
container.removeListener('
|
|
50
|
+
container.removeListener('pointerup');
|
|
51
51
|
}
|
|
52
52
|
if (touchComp.props.onTouchEnd) {
|
|
53
|
-
container.removeListener('
|
|
53
|
+
container.removeListener('pointercancel');
|
|
54
54
|
}
|
|
55
55
|
});
|
|
56
56
|
}
|