@vived/app 4.34.2 → 4.34.3
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.
|
@@ -4,6 +4,7 @@ exports.makeHoverAppObject = exports.HoverAppObjectUC = void 0;
|
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const AppObjectUC_1 = require("../../../AppObject/AppObjectUC");
|
|
6
6
|
const Babylon_1 = require("../../Babylon");
|
|
7
|
+
const BaseApp_1 = require("../../BaseApp");
|
|
7
8
|
const Selectable_1 = require("../Entities/Selectable");
|
|
8
9
|
const Selection_1 = require("../Entities/Selection");
|
|
9
10
|
class HoverAppObjectUC extends AppObjectUC_1.AppObjectUC {
|
|
@@ -21,10 +22,16 @@ class HoverAppObjectUCImp extends HoverAppObjectUC {
|
|
|
21
22
|
constructor(appObject) {
|
|
22
23
|
super(appObject, HoverAppObjectUC.type);
|
|
23
24
|
this.allowHover = () => {
|
|
24
|
-
|
|
25
|
+
if (!this.baseApp) {
|
|
26
|
+
return false;
|
|
27
|
+
}
|
|
28
|
+
return this.baseApp.isAuthoring;
|
|
25
29
|
};
|
|
26
30
|
this.allowTryHover = () => {
|
|
27
|
-
|
|
31
|
+
if (!this.baseApp) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return this.baseApp.isAuthoring;
|
|
28
35
|
};
|
|
29
36
|
this.tryHoverAppObject = (ray) => {
|
|
30
37
|
if (!this.selection)
|
|
@@ -60,4 +67,7 @@ class HoverAppObjectUCImp extends HoverAppObjectUC {
|
|
|
60
67
|
get selection() {
|
|
61
68
|
return this.getCachedSingleton(Selection_1.Selection.type);
|
|
62
69
|
}
|
|
70
|
+
get baseApp() {
|
|
71
|
+
return this.getCachedSingleton(BaseApp_1.BaseAppState.type);
|
|
72
|
+
}
|
|
63
73
|
}
|
|
@@ -4,6 +4,7 @@ exports.makePressAppObject = exports.PressAppObjectUC = void 0;
|
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const AppObjectUC_1 = require("../../../AppObject/AppObjectUC");
|
|
6
6
|
const Babylon_1 = require("../../Babylon");
|
|
7
|
+
const BaseApp_1 = require("../../BaseApp");
|
|
7
8
|
const Selectable_1 = require("../Entities/Selectable");
|
|
8
9
|
const Selection_1 = require("../Entities/Selection");
|
|
9
10
|
class PressAppObjectUC extends AppObjectUC_1.AppObjectUC {
|
|
@@ -21,10 +22,16 @@ class PressAppObjectUCImp extends PressAppObjectUC {
|
|
|
21
22
|
constructor(appObject) {
|
|
22
23
|
super(appObject, PressAppObjectUC.type);
|
|
23
24
|
this.allowPress = () => {
|
|
24
|
-
|
|
25
|
+
if (!this.baseApp) {
|
|
26
|
+
return false;
|
|
27
|
+
}
|
|
28
|
+
return this.baseApp.isAuthoring;
|
|
25
29
|
};
|
|
26
30
|
this.allowTryPress = () => {
|
|
27
|
-
|
|
31
|
+
if (!this.baseApp) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return this.baseApp.isAuthoring;
|
|
28
35
|
};
|
|
29
36
|
this.tryPressAppObject = (ray) => {
|
|
30
37
|
if (!this.selection)
|
|
@@ -61,4 +68,7 @@ class PressAppObjectUCImp extends PressAppObjectUC {
|
|
|
61
68
|
get selection() {
|
|
62
69
|
return this.getCachedSingleton(Selection_1.Selection.type);
|
|
63
70
|
}
|
|
71
|
+
get baseApp() {
|
|
72
|
+
return this.getCachedSingleton(BaseApp_1.BaseAppState.type);
|
|
73
|
+
}
|
|
64
74
|
}
|
|
@@ -4,6 +4,7 @@ exports.makeSelectAppObject = exports.SelectAppObjectUC = void 0;
|
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const AppObjectUC_1 = require("../../../AppObject/AppObjectUC");
|
|
6
6
|
const Babylon_1 = require("../../Babylon");
|
|
7
|
+
const BaseApp_1 = require("../../BaseApp");
|
|
7
8
|
const Selectable_1 = require("../Entities/Selectable");
|
|
8
9
|
const Selection_1 = require("../Entities/Selection");
|
|
9
10
|
class SelectAppObjectUC extends AppObjectUC_1.AppObjectUC {
|
|
@@ -21,10 +22,16 @@ class SelectAppObjectUCImp extends SelectAppObjectUC {
|
|
|
21
22
|
constructor(appObject) {
|
|
22
23
|
super(appObject, SelectAppObjectUC.type);
|
|
23
24
|
this.allowSelect = () => {
|
|
24
|
-
|
|
25
|
+
if (!this.baseApp) {
|
|
26
|
+
return false;
|
|
27
|
+
}
|
|
28
|
+
return this.baseApp.isAuthoring;
|
|
25
29
|
};
|
|
26
30
|
this.allowTrySelect = () => {
|
|
27
|
-
|
|
31
|
+
if (!this.baseApp) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return this.baseApp.isAuthoring;
|
|
28
35
|
};
|
|
29
36
|
this.trySelectAppObject = (ray) => {
|
|
30
37
|
if (!this.selection)
|
|
@@ -60,4 +67,7 @@ class SelectAppObjectUCImp extends SelectAppObjectUC {
|
|
|
60
67
|
get selection() {
|
|
61
68
|
return this.getCachedSingleton(Selection_1.Selection.type);
|
|
62
69
|
}
|
|
70
|
+
get baseApp() {
|
|
71
|
+
return this.getCachedSingleton(BaseApp_1.BaseAppState.type);
|
|
72
|
+
}
|
|
63
73
|
}
|