@vived/app 4.30.0 → 4.32.0
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/lib/Components/BaseApp/Factories/setupBaseApp.d.ts +2 -2
- package/lib/Components/BaseApp/Factories/setupBaseApp.js +1 -0
- package/lib/Components/ChannelModel/UC/SelectChannelModelUC.js +7 -0
- package/lib/Components/InspectorTab/Adapters/index.d.ts +1 -0
- package/lib/Components/InspectorTab/Adapters/index.js +13 -0
- package/lib/Components/InspectorTab/Adapters/inspectorTabAdapter.d.ts +3 -0
- package/lib/Components/InspectorTab/Adapters/inspectorTabAdapter.js +23 -0
- package/lib/Components/InspectorTab/Controllers/KeyboardToSetTab.d.ts +10 -0
- package/lib/Components/InspectorTab/Controllers/KeyboardToSetTab.js +45 -0
- package/lib/Components/InspectorTab/Controllers/clickSetInspectorTab.d.ts +2 -0
- package/lib/Components/InspectorTab/Controllers/clickSetInspectorTab.js +13 -0
- package/lib/Components/InspectorTab/Controllers/clickSetInspectorTabIndex.d.ts +2 -0
- package/lib/Components/InspectorTab/Controllers/clickSetInspectorTabIndex.js +13 -0
- package/lib/Components/InspectorTab/Controllers/index.d.ts +3 -0
- package/lib/Components/InspectorTab/Controllers/index.js +15 -0
- package/lib/Components/InspectorTab/Entities/InspectorTabEntity.d.ts +12 -0
- package/lib/Components/InspectorTab/Entities/InspectorTabEntity.js +54 -0
- package/lib/Components/InspectorTab/Entities/index.d.ts +1 -0
- package/lib/Components/InspectorTab/Entities/index.js +13 -0
- package/lib/Components/InspectorTab/Factories/index.d.ts +1 -0
- package/lib/Components/InspectorTab/Factories/index.js +13 -0
- package/lib/Components/InspectorTab/Factories/setupInspectorTabs.d.ts +2 -0
- package/lib/Components/InspectorTab/Factories/setupInspectorTabs.js +17 -0
- package/lib/Components/InspectorTab/Mocks/InspectorTabPmMock.d.ts +8 -0
- package/lib/Components/InspectorTab/Mocks/InspectorTabPmMock.js +15 -0
- package/lib/Components/InspectorTab/Mocks/index.d.ts +1 -0
- package/lib/Components/InspectorTab/Mocks/index.js +13 -0
- package/lib/Components/InspectorTab/PMs/InspectorTabPM.d.ts +12 -0
- package/lib/Components/InspectorTab/PMs/InspectorTabPM.js +55 -0
- package/lib/Components/InspectorTab/PMs/index.d.ts +1 -0
- package/lib/Components/InspectorTab/PMs/index.js +13 -0
- package/lib/Components/InspectorTab/index.d.ts +6 -0
- package/lib/Components/InspectorTab/index.js +18 -0
- package/lib/Components/MouseInput/Factories/index.d.ts +1 -0
- package/lib/Components/MouseInput/Factories/index.js +13 -0
- package/lib/Components/MouseInput/Factories/setupMouseInput.d.ts +2 -0
- package/lib/Components/MouseInput/Factories/setupMouseInput.js +9 -0
- package/lib/Components/MouseInput/index.d.ts +1 -0
- package/lib/Components/MouseInput/index.js +1 -0
- package/lib/Components/OverlayColor/UC/SerializeOverlayColoredObjects.d.ts +27 -0
- package/lib/Components/OverlayColor/UC/SerializeOverlayColoredObjects.js +87 -0
- package/lib/Components/OverlayColor/UC/index.d.ts +1 -0
- package/lib/Components/OverlayColor/UC/index.js +1 -0
- package/lib/Components/SceneRoot/Controllers/DoubleTapToFocus.d.ts +1 -1
- package/lib/Components/SceneRoot/Controllers/DoubleTapToFocus.js +3 -5
- package/lib/Components/SceneRoot/Controllers/MouseClickToFocus.d.ts +1 -1
- package/lib/Components/SceneRoot/Controllers/MouseClickToFocus.js +6 -5
- package/lib/Components/SceneRoot/Controllers/MouseDoubleClickToRecenter.d.ts +1 -1
- package/lib/Components/SceneRoot/Controllers/MouseDoubleClickToRecenter.js +3 -5
- package/lib/Components/SceneRoot/Controllers/MouseOrbit.d.ts +2 -1
- package/lib/Components/SceneRoot/Controllers/MouseOrbit.js +19 -6
- package/lib/Components/SceneRoot/Controllers/MousePan.d.ts +2 -1
- package/lib/Components/SceneRoot/Controllers/MousePan.js +19 -6
- package/lib/Components/SceneRoot/Controllers/MouseRoll.d.ts +1 -1
- package/lib/Components/SceneRoot/Controllers/MouseRoll.js +3 -5
- package/lib/Components/SceneRoot/Controllers/MouseScale.d.ts +2 -1
- package/lib/Components/SceneRoot/Controllers/MouseScale.js +16 -6
- package/lib/Components/SceneRoot/Controllers/ScaleSceneRootSC.d.ts +2 -2
- package/lib/Components/SceneRoot/Controllers/ScaleSceneRootSC.js +8 -11
- package/lib/Components/SceneRoot/Controllers/SceneRootMoveSC.d.ts +2 -2
- package/lib/Components/SceneRoot/Controllers/SceneRootMoveSC.js +9 -12
- package/lib/Components/SceneRoot/Controllers/TouchOrbit.d.ts +3 -1
- package/lib/Components/SceneRoot/Controllers/TouchOrbit.js +24 -6
- package/lib/Components/SceneRoot/Controllers/TouchPan.d.ts +3 -1
- package/lib/Components/SceneRoot/Controllers/TouchPan.js +24 -6
- package/lib/Components/SceneRoot/Controllers/TouchPinch.d.ts +2 -2
- package/lib/Components/SceneRoot/Controllers/TouchPinch.js +12 -6
- package/lib/Components/SceneRoot/Controllers/TouchScale.d.ts +2 -2
- package/lib/Components/SceneRoot/Controllers/TouchScale.js +16 -5
- package/lib/Components/SceneRoot/Factories/index.d.ts +1 -0
- package/lib/Components/SceneRoot/Factories/index.js +13 -0
- package/lib/Components/SceneRoot/Factories/setupSceneRoot.d.ts +3 -0
- package/lib/Components/SceneRoot/Factories/setupSceneRoot.js +45 -0
- package/lib/Components/SceneRoot/Mocks/DragScaleSceneRootUcMock.d.ts +9 -0
- package/lib/Components/SceneRoot/Mocks/DragScaleSceneRootUcMock.js +13 -0
- package/lib/Components/SceneRoot/Mocks/MockDragScaleSceneRootUC.d.ts +9 -0
- package/lib/Components/SceneRoot/Mocks/MockDragScaleSceneRootUC.js +13 -0
- package/lib/Components/SceneRoot/Mocks/MockFocusOnPixelUC.d.ts +10 -0
- package/lib/Components/SceneRoot/Mocks/MockFocusOnPixelUC.js +15 -0
- package/lib/Components/SceneRoot/Mocks/MockOrbitSceneRootUC.d.ts +11 -0
- package/lib/Components/SceneRoot/Mocks/MockOrbitSceneRootUC.js +15 -0
- package/lib/Components/SceneRoot/Mocks/MockPanSceneRootUC.d.ts +10 -0
- package/lib/Components/SceneRoot/Mocks/MockPanSceneRootUC.js +14 -0
- package/lib/Components/SceneRoot/Mocks/MockPinchSceneRootUC.d.ts +10 -0
- package/lib/Components/SceneRoot/Mocks/MockPinchSceneRootUC.js +14 -0
- package/lib/Components/SceneRoot/Mocks/OrbitSceneRootUcMock.d.ts +11 -0
- package/lib/Components/SceneRoot/Mocks/OrbitSceneRootUcMock.js +15 -0
- package/lib/Components/SceneRoot/Mocks/PanSceneRootUcMock.d.ts +10 -0
- package/lib/Components/SceneRoot/Mocks/PanSceneRootUcMock.js +14 -0
- package/lib/Components/SceneRoot/Mocks/index.d.ts +5 -0
- package/lib/Components/SceneRoot/Mocks/index.js +17 -0
- package/lib/Components/SceneRoot/UC/CenterSceneRootOnPixelPick.js +1 -1
- package/lib/Components/SceneRoot/UC/FocusOnPixel.js +1 -1
- package/lib/Components/SceneRoot/index.d.ts +3 -1
- package/lib/Components/SceneRoot/index.js +3 -1
- package/lib/Components/Selection/Controller/KeyboardToClearSelection.d.ts +8 -0
- package/lib/Components/Selection/Controller/KeyboardToClearSelection.js +23 -0
- package/lib/Components/Selection/Controller/index.d.ts +1 -0
- package/lib/Components/Selection/Controller/index.js +1 -0
- package/lib/Components/Selection/Factories/index.d.ts +1 -0
- package/lib/Components/Selection/Factories/index.js +13 -0
- package/lib/Components/Selection/Factories/setupSelection.d.ts +2 -0
- package/lib/Components/Selection/Factories/setupSelection.js +27 -0
- package/lib/Components/Selection/index.d.ts +1 -0
- package/lib/Components/Selection/index.js +1 -0
- package/lib/Components/Stick/UCs/TryStickAppObjectUC.js +10 -0
- package/lib/Components/StoredView/Adapters/hasStoredViewAdapter.d.ts +2 -0
- package/lib/Components/StoredView/Adapters/hasStoredViewAdapter.js +19 -0
- package/lib/Components/StoredView/Adapters/index.d.ts +1 -0
- package/lib/Components/StoredView/Adapters/index.js +13 -0
- package/lib/Components/StoredView/Controllers/clearStoredView.d.ts +2 -0
- package/lib/Components/StoredView/Controllers/clearStoredView.js +13 -0
- package/lib/Components/StoredView/Controllers/index.d.ts +4 -0
- package/lib/Components/StoredView/Controllers/index.js +16 -0
- package/lib/Components/StoredView/Controllers/restoreStoredView.d.ts +2 -0
- package/lib/Components/StoredView/Controllers/restoreStoredView.js +13 -0
- package/lib/Components/StoredView/Controllers/setViewInXR.d.ts +2 -0
- package/lib/Components/StoredView/Controllers/setViewInXR.js +13 -0
- package/lib/Components/StoredView/Controllers/storeCurrentView.d.ts +2 -0
- package/lib/Components/StoredView/Controllers/storeCurrentView.js +13 -0
- package/lib/Components/StoredView/Factories/index.d.ts +1 -0
- package/lib/Components/StoredView/Factories/index.js +13 -0
- package/lib/Components/StoredView/Factories/setupStoredView.d.ts +2 -0
- package/lib/Components/StoredView/Factories/setupStoredView.js +21 -0
- package/lib/Components/StoredView/Mocks/ClearStoredViewUcMock.d.ts +8 -0
- package/lib/Components/StoredView/Mocks/ClearStoredViewUcMock.js +15 -0
- package/lib/Components/StoredView/Mocks/HasStoredViewPmMock.d.ts +8 -0
- package/lib/Components/StoredView/Mocks/HasStoredViewPmMock.js +15 -0
- package/lib/Components/StoredView/Mocks/RestoreStoredViewUcMock.d.ts +9 -0
- package/lib/Components/StoredView/Mocks/RestoreStoredViewUcMock.js +17 -0
- package/lib/Components/StoredView/Mocks/SetViewInXRUcMock.d.ts +8 -0
- package/lib/Components/StoredView/Mocks/SetViewInXRUcMock.js +15 -0
- package/lib/Components/StoredView/Mocks/StoreCurrentViewUcMock.d.ts +8 -0
- package/lib/Components/StoredView/Mocks/StoreCurrentViewUcMock.js +15 -0
- package/lib/Components/StoredView/Mocks/index.d.ts +1 -0
- package/lib/Components/StoredView/Mocks/index.js +13 -0
- package/lib/Components/StoredView/PM/HasStoredViewPM.js +7 -9
- package/lib/Components/StoredView/UC/ClearStoredViewUC.d.ts +0 -1
- package/lib/Components/StoredView/UC/ClearStoredViewUC.js +4 -15
- package/lib/Components/StoredView/UC/RestoreStoredViewUC.d.ts +0 -1
- package/lib/Components/StoredView/UC/RestoreStoredViewUC.js +8 -22
- package/lib/Components/StoredView/UC/SerializeStoredView.js +3 -6
- package/lib/Components/StoredView/UC/SetInXRUC.d.ts +0 -1
- package/lib/Components/StoredView/UC/SetInXRUC.js +4 -15
- package/lib/Components/StoredView/UC/StoreCurrentViewUC.d.ts +0 -1
- package/lib/Components/StoredView/UC/StoreCurrentViewUC.js +7 -19
- package/lib/Components/StoredView/index.d.ts +3 -0
- package/lib/Components/StoredView/index.js +3 -0
- package/lib/Components/Tools/Adapters/toolAdapter.d.ts +1 -1
- package/lib/Components/Tools/Adapters/toolAdapter.js +16 -23
- package/lib/Components/Tools/Controller/ToolHotkeys.d.ts +1 -1
- package/lib/Components/Tools/Controller/triggerTool.d.ts +1 -1
- package/lib/Components/Tools/Entities/ToolEntity.d.ts +7 -7
- package/lib/Components/Tools/Entities/ToolEntity.js +1 -2
- package/lib/Components/Tools/Entities/ToolRepository.d.ts +12 -11
- package/lib/Components/Tools/Entities/ToolRepository.js +30 -26
- package/lib/Components/Tools/Factories/index.d.ts +1 -0
- package/lib/Components/Tools/Factories/index.js +13 -0
- package/lib/Components/Tools/Factories/setupTools.d.ts +3 -0
- package/lib/Components/Tools/Factories/setupTools.js +15 -0
- package/lib/Components/Tools/Factories/toolFactory.d.ts +3 -0
- package/lib/Components/Tools/Factories/toolFactory.js +14 -0
- package/lib/Components/Tools/Mocks/MockToolRepo.d.ts +17 -0
- package/lib/Components/Tools/Mocks/MockToolRepo.js +28 -0
- package/lib/Components/Tools/Mocks/ToolPMMock.d.ts +2 -2
- package/lib/Components/Tools/Mocks/index.d.ts +1 -0
- package/lib/Components/Tools/Mocks/index.js +1 -0
- package/lib/Components/Tools/PM/ToolPM.d.ts +6 -6
- package/lib/Components/Tools/index.d.ts +1 -0
- package/lib/Components/Tools/index.js +1 -0
- package/lib/Components/TouchController/Factories/index.d.ts +1 -0
- package/lib/Components/TouchController/Factories/index.js +13 -0
- package/lib/Components/TouchController/Factories/setupTouchInput.d.ts +2 -0
- package/lib/Components/TouchController/Factories/setupTouchInput.js +9 -0
- package/lib/Components/TouchController/index.d.ts +1 -0
- package/lib/Components/TouchController/index.js +1 -0
- package/lib/Components/UndoRedo/Factories/index.d.ts +1 -0
- package/lib/Components/UndoRedo/Factories/index.js +13 -0
- package/lib/Components/UndoRedo/Factories/setupUndoRedo.d.ts +2 -0
- package/lib/Components/UndoRedo/Factories/setupUndoRedo.js +18 -0
- package/lib/Components/UndoRedo/UCs/UndoRedoButtonStatesHook.d.ts +11 -0
- package/lib/Components/UndoRedo/UCs/UndoRedoButtonStatesHook.js +55 -0
- package/lib/Components/UndoRedo/UCs/index.d.ts +1 -0
- package/lib/Components/UndoRedo/UCs/index.js +13 -0
- package/lib/Components/UndoRedo/index.d.ts +3 -1
- package/lib/Components/UndoRedo/index.js +3 -1
- package/lib/Components/index.d.ts +1 -0
- package/lib/Components/index.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.restoreStoredView = void 0;
|
|
4
|
+
const RestoreStoredViewUC_1 = require("../UC/RestoreStoredViewUC");
|
|
5
|
+
function restoreStoredView(appObjects) {
|
|
6
|
+
const uc = RestoreStoredViewUC_1.RestoreStoredViewUC.get(appObjects);
|
|
7
|
+
if (!uc) {
|
|
8
|
+
appObjects.submitError("restoreStoredView", "Unable to find RestoreStoredViewUC");
|
|
9
|
+
return;
|
|
10
|
+
}
|
|
11
|
+
uc.restoreStoredView();
|
|
12
|
+
}
|
|
13
|
+
exports.restoreStoredView = restoreStoredView;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setViewInXR = void 0;
|
|
4
|
+
const SetInXRUC_1 = require("../UC/SetInXRUC");
|
|
5
|
+
function setViewInXR(appObjects) {
|
|
6
|
+
const uc = SetInXRUC_1.SetViewInXRUC.get(appObjects);
|
|
7
|
+
if (!uc) {
|
|
8
|
+
appObjects.submitError("setViewInXR", "Unable to find SetViewInXRUC");
|
|
9
|
+
return;
|
|
10
|
+
}
|
|
11
|
+
uc.setViewInXR();
|
|
12
|
+
}
|
|
13
|
+
exports.setViewInXR = setViewInXR;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.storeCurrentView = void 0;
|
|
4
|
+
const StoreCurrentViewUC_1 = require("../UC/StoreCurrentViewUC");
|
|
5
|
+
function storeCurrentView(appObjects) {
|
|
6
|
+
const uc = StoreCurrentViewUC_1.StoreCurrentViewUC.get(appObjects);
|
|
7
|
+
if (!uc) {
|
|
8
|
+
appObjects.submitError("storeCurrentView", "Unable to find StoreCurrentViewUC");
|
|
9
|
+
return;
|
|
10
|
+
}
|
|
11
|
+
uc.storeCurrentView();
|
|
12
|
+
}
|
|
13
|
+
exports.storeCurrentView = storeCurrentView;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./setupStoredView";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupStoredView"), exports);
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupStoredView = void 0;
|
|
4
|
+
const Entities_1 = require("../Entities");
|
|
5
|
+
const PM_1 = require("../PM");
|
|
6
|
+
const UC_1 = require("../UC");
|
|
7
|
+
function setupStoredView(appObjects) {
|
|
8
|
+
const ao = appObjects.getOrCreate("StoredView");
|
|
9
|
+
// Entities
|
|
10
|
+
Entities_1.makeStoredView(ao);
|
|
11
|
+
// UCs
|
|
12
|
+
UC_1.makeStoreCurrentViewUC(ao);
|
|
13
|
+
UC_1.makeRestoreStoredViewUC(ao);
|
|
14
|
+
UC_1.makeClearStoredViewUC(ao);
|
|
15
|
+
UC_1.makeSetViewInXRUC(ao);
|
|
16
|
+
UC_1.makeSerializeStoredView(ao);
|
|
17
|
+
// PMs
|
|
18
|
+
PM_1.makeHasStoredViewPM(ao);
|
|
19
|
+
return ao;
|
|
20
|
+
}
|
|
21
|
+
exports.setupStoredView = setupStoredView;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="jest" />
|
|
2
|
+
import { AppObject, AppObjectRepo } from "../../../AppObject";
|
|
3
|
+
import { ClearStoredViewUC } from "../UC/ClearStoredViewUC";
|
|
4
|
+
export declare class ClearStoredViewUcMock extends ClearStoredViewUC {
|
|
5
|
+
clearStoredView: jest.Mock<any, any>;
|
|
6
|
+
constructor(appObject: AppObject);
|
|
7
|
+
}
|
|
8
|
+
export declare function makeClearStoredViewUcMock(appObjects: AppObjectRepo): ClearStoredViewUcMock;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeClearStoredViewUcMock = exports.ClearStoredViewUcMock = void 0;
|
|
4
|
+
const ClearStoredViewUC_1 = require("../UC/ClearStoredViewUC");
|
|
5
|
+
class ClearStoredViewUcMock extends ClearStoredViewUC_1.ClearStoredViewUC {
|
|
6
|
+
constructor(appObject) {
|
|
7
|
+
super(appObject, ClearStoredViewUC_1.ClearStoredViewUC.type);
|
|
8
|
+
this.clearStoredView = jest.fn();
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.ClearStoredViewUcMock = ClearStoredViewUcMock;
|
|
12
|
+
function makeClearStoredViewUcMock(appObjects) {
|
|
13
|
+
return new ClearStoredViewUcMock(appObjects.getOrCreate("ClearStoredViewUcMock"));
|
|
14
|
+
}
|
|
15
|
+
exports.makeClearStoredViewUcMock = makeClearStoredViewUcMock;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="jest" />
|
|
2
|
+
import { AppObject, AppObjectRepo } from "../../../AppObject";
|
|
3
|
+
import { HasStoredViewPM } from "../PM/HasStoredViewPM";
|
|
4
|
+
export declare class HasStoredViewPmMock extends HasStoredViewPM {
|
|
5
|
+
vmsAreEqual: jest.Mock<any, any>;
|
|
6
|
+
constructor(appObject: AppObject);
|
|
7
|
+
}
|
|
8
|
+
export declare function makeHasStoredViewPmMock(appObjects: AppObjectRepo): HasStoredViewPmMock;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeHasStoredViewPmMock = exports.HasStoredViewPmMock = void 0;
|
|
4
|
+
const HasStoredViewPM_1 = require("../PM/HasStoredViewPM");
|
|
5
|
+
class HasStoredViewPmMock extends HasStoredViewPM_1.HasStoredViewPM {
|
|
6
|
+
constructor(appObject) {
|
|
7
|
+
super(appObject, HasStoredViewPM_1.HasStoredViewPM.type);
|
|
8
|
+
this.vmsAreEqual = jest.fn();
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.HasStoredViewPmMock = HasStoredViewPmMock;
|
|
12
|
+
function makeHasStoredViewPmMock(appObjects) {
|
|
13
|
+
return new HasStoredViewPmMock(appObjects.getOrCreate("HasStoredViewPmMock"));
|
|
14
|
+
}
|
|
15
|
+
exports.makeHasStoredViewPmMock = makeHasStoredViewPmMock;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="jest" />
|
|
2
|
+
import { AppObject, AppObjectRepo } from "../../../AppObject";
|
|
3
|
+
import { RestoreStoredViewUC } from "../UC/RestoreStoredViewUC";
|
|
4
|
+
export declare class RestoreStoredViewUcMock extends RestoreStoredViewUC {
|
|
5
|
+
restoreStoredView: jest.Mock<any, any>;
|
|
6
|
+
ease: import("../../..").EaseFn;
|
|
7
|
+
constructor(appObject: AppObject);
|
|
8
|
+
}
|
|
9
|
+
export declare function makeRestoreStoredViewUcMock(appObjects: AppObjectRepo): RestoreStoredViewUcMock;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeRestoreStoredViewUcMock = exports.RestoreStoredViewUcMock = void 0;
|
|
4
|
+
const Utilities_1 = require("../../../Utilities");
|
|
5
|
+
const RestoreStoredViewUC_1 = require("../UC/RestoreStoredViewUC");
|
|
6
|
+
class RestoreStoredViewUcMock extends RestoreStoredViewUC_1.RestoreStoredViewUC {
|
|
7
|
+
constructor(appObject) {
|
|
8
|
+
super(appObject, RestoreStoredViewUC_1.RestoreStoredViewUC.type);
|
|
9
|
+
this.restoreStoredView = jest.fn();
|
|
10
|
+
this.ease = Utilities_1.easeLinear;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
exports.RestoreStoredViewUcMock = RestoreStoredViewUcMock;
|
|
14
|
+
function makeRestoreStoredViewUcMock(appObjects) {
|
|
15
|
+
return new RestoreStoredViewUcMock(appObjects.getOrCreate("RestoreStoredViewUcMock"));
|
|
16
|
+
}
|
|
17
|
+
exports.makeRestoreStoredViewUcMock = makeRestoreStoredViewUcMock;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="jest" />
|
|
2
|
+
import { AppObject, AppObjectRepo } from "../../../AppObject";
|
|
3
|
+
import { SetViewInXRUC } from "../UC/SetInXRUC";
|
|
4
|
+
export declare class SetViewInXRUcMock extends SetViewInXRUC {
|
|
5
|
+
setViewInXR: jest.Mock<any, any>;
|
|
6
|
+
constructor(appObject: AppObject);
|
|
7
|
+
}
|
|
8
|
+
export declare function makeSetViewInXRUcMock(appObjects: AppObjectRepo): SetViewInXRUcMock;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeSetViewInXRUcMock = exports.SetViewInXRUcMock = void 0;
|
|
4
|
+
const SetInXRUC_1 = require("../UC/SetInXRUC");
|
|
5
|
+
class SetViewInXRUcMock extends SetInXRUC_1.SetViewInXRUC {
|
|
6
|
+
constructor(appObject) {
|
|
7
|
+
super(appObject, SetInXRUC_1.SetViewInXRUC.type);
|
|
8
|
+
this.setViewInXR = jest.fn();
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.SetViewInXRUcMock = SetViewInXRUcMock;
|
|
12
|
+
function makeSetViewInXRUcMock(appObjects) {
|
|
13
|
+
return new SetViewInXRUcMock(appObjects.getOrCreate("SetViewInXRUcMock"));
|
|
14
|
+
}
|
|
15
|
+
exports.makeSetViewInXRUcMock = makeSetViewInXRUcMock;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="jest" />
|
|
2
|
+
import { AppObject, AppObjectRepo } from "../../../AppObject";
|
|
3
|
+
import { StoreCurrentViewUC } from "../UC/StoreCurrentViewUC";
|
|
4
|
+
export declare class StoreCurrentViewUcMock extends StoreCurrentViewUC {
|
|
5
|
+
storeCurrentView: jest.Mock<any, any>;
|
|
6
|
+
constructor(appObject: AppObject);
|
|
7
|
+
}
|
|
8
|
+
export declare function makeStoreCurrentViewUcMock(appObjects: AppObjectRepo): StoreCurrentViewUcMock;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeStoreCurrentViewUcMock = exports.StoreCurrentViewUcMock = void 0;
|
|
4
|
+
const StoreCurrentViewUC_1 = require("../UC/StoreCurrentViewUC");
|
|
5
|
+
class StoreCurrentViewUcMock extends StoreCurrentViewUC_1.StoreCurrentViewUC {
|
|
6
|
+
constructor(appObject) {
|
|
7
|
+
super(appObject, StoreCurrentViewUC_1.StoreCurrentViewUC.type);
|
|
8
|
+
this.storeCurrentView = jest.fn();
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.StoreCurrentViewUcMock = StoreCurrentViewUcMock;
|
|
12
|
+
function makeStoreCurrentViewUcMock(appObjects) {
|
|
13
|
+
return new StoreCurrentViewUcMock(appObjects.getOrCreate("StoreCurrentViewUcMock"));
|
|
14
|
+
}
|
|
15
|
+
exports.makeStoreCurrentViewUcMock = makeStoreCurrentViewUcMock;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./HasStoredViewPmMock";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./HasStoredViewPmMock"), exports);
|
|
@@ -14,6 +14,7 @@ function makeHasStoredViewPM(appObject) {
|
|
|
14
14
|
exports.makeHasStoredViewPM = makeHasStoredViewPM;
|
|
15
15
|
class HasStoredViewPMImp extends HasStoredViewPM {
|
|
16
16
|
constructor(appObject) {
|
|
17
|
+
var _a;
|
|
17
18
|
super(appObject, HasStoredViewPM.type);
|
|
18
19
|
this.onRepoChange = () => {
|
|
19
20
|
if (!this.storedView)
|
|
@@ -26,15 +27,12 @@ class HasStoredViewPMImp extends HasStoredViewPM {
|
|
|
26
27
|
(_a = this.storedView) === null || _a === void 0 ? void 0 : _a.removeChangeObserver(this.onRepoChange);
|
|
27
28
|
(_b = this.storedView) === null || _b === void 0 ? void 0 : _b.removeOnDisposeObserver(this.dispose);
|
|
28
29
|
};
|
|
29
|
-
this.storedView
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
else {
|
|
36
|
-
console.warn("[HasStoredViewPMImp] App Object does not have a StoredView Entity");
|
|
37
|
-
}
|
|
30
|
+
(_a = this.storedView) === null || _a === void 0 ? void 0 : _a.addChangeObserver(this.onRepoChange);
|
|
31
|
+
this.onRepoChange();
|
|
32
|
+
this.appObjects.registerSingleton(this);
|
|
33
|
+
}
|
|
34
|
+
get storedView() {
|
|
35
|
+
return this.getCachedSingleton(Entities_1.StoredView.type);
|
|
38
36
|
}
|
|
39
37
|
vmsAreEqual(a, b) {
|
|
40
38
|
return a === b;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.makeClearStoredViewUC = exports.ClearStoredViewUC = void 0;
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const ValueObjects_1 = require("../../../ValueObjects");
|
|
6
6
|
const Dispatcher_1 = require("../../Dispatcher");
|
|
@@ -14,16 +14,6 @@ function makeClearStoredViewUC(appObject) {
|
|
|
14
14
|
return new ClearStoredViewUCImp(appObject);
|
|
15
15
|
}
|
|
16
16
|
exports.makeClearStoredViewUC = makeClearStoredViewUC;
|
|
17
|
-
function clearStoredView(appObjects) {
|
|
18
|
-
const uc = ClearStoredViewUC.get(appObjects);
|
|
19
|
-
if (uc) {
|
|
20
|
-
uc.clearStoredView();
|
|
21
|
-
}
|
|
22
|
-
else {
|
|
23
|
-
appObjects.submitWarning("clearStoredView", "Can't find ClearStoredViewUC");
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
exports.clearStoredView = clearStoredView;
|
|
27
17
|
class ClearStoredViewUCImp extends ClearStoredViewUC {
|
|
28
18
|
constructor(appObject) {
|
|
29
19
|
super(appObject, ClearStoredViewUC.type);
|
|
@@ -36,9 +26,8 @@ class ClearStoredViewUCImp extends ClearStoredViewUC {
|
|
|
36
26
|
this.storedView.hasStoredView = false;
|
|
37
27
|
Dispatcher_1.dispatchStateChange(this.appObject.appObjectRepo);
|
|
38
28
|
};
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
}
|
|
29
|
+
}
|
|
30
|
+
get storedView() {
|
|
31
|
+
return this.getCachedSingleton(Entities_1.StoredView.type);
|
|
43
32
|
}
|
|
44
33
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.makeRestoreStoredViewUC = exports.RestoreStoredViewUC = void 0;
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const Utilities_1 = require("../../../Utilities");
|
|
6
6
|
const ValueObjects_1 = require("../../../ValueObjects");
|
|
@@ -15,20 +15,10 @@ function makeRestoreStoredViewUC(appObject) {
|
|
|
15
15
|
return new RestoreStoredViewUCImp(appObject);
|
|
16
16
|
}
|
|
17
17
|
exports.makeRestoreStoredViewUC = makeRestoreStoredViewUC;
|
|
18
|
-
function restoreStoredView(appObjects) {
|
|
19
|
-
const uc = RestoreStoredViewUC.get(appObjects);
|
|
20
|
-
if (uc) {
|
|
21
|
-
uc.restoreStoredView();
|
|
22
|
-
}
|
|
23
|
-
else {
|
|
24
|
-
appObjects.submitWarning("restoreStoredView", "Can't find ClearStoredViewUC");
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
exports.restoreStoredView = restoreStoredView;
|
|
28
18
|
class RestoreStoredViewUCImp extends RestoreStoredViewUC {
|
|
29
19
|
constructor(appObject) {
|
|
30
20
|
super(appObject, RestoreStoredViewUC.type);
|
|
31
|
-
this.ease = Utilities_1.
|
|
21
|
+
this.ease = Utilities_1.cubicInOut;
|
|
32
22
|
this.restoreStoredView = () => {
|
|
33
23
|
if (this.storedView && this.sceneRoot) {
|
|
34
24
|
if (!this.storedView.hasStoredView)
|
|
@@ -47,15 +37,11 @@ class RestoreStoredViewUCImp extends RestoreStoredViewUC {
|
|
|
47
37
|
this.warn("Missing necessary entities");
|
|
48
38
|
}
|
|
49
39
|
};
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
this.
|
|
56
|
-
if (!this.storedView) {
|
|
57
|
-
this.error("Unable to find stored view");
|
|
58
|
-
return;
|
|
59
|
-
}
|
|
40
|
+
}
|
|
41
|
+
get storedView() {
|
|
42
|
+
return this.getCachedSingleton(Entities_1.StoredView.type);
|
|
43
|
+
}
|
|
44
|
+
get sceneRoot() {
|
|
45
|
+
return this.getCachedSingleton(SceneRoot_1.SceneRootEntity.type);
|
|
60
46
|
}
|
|
61
47
|
}
|
|
@@ -21,12 +21,6 @@ class SerializeStoredViewImp extends SerializeStoredView {
|
|
|
21
21
|
constructor(appObject) {
|
|
22
22
|
super(appObject, SerializeStoredView.type);
|
|
23
23
|
this.seriliziationVersion = 1;
|
|
24
|
-
this.storedView = appObject.getComponent(StoredView_1.StoredView.type);
|
|
25
|
-
if (!this.storedView) {
|
|
26
|
-
console.warn("SerializeStoredView UC has been added to an App Object that does not have a StoredView Entity. Add one before adding the UC");
|
|
27
|
-
this.dispose();
|
|
28
|
-
return;
|
|
29
|
-
}
|
|
30
24
|
const stateMachine = StateMachineEntity_1.StateMachineEntity.get(appObject.appObjectRepo);
|
|
31
25
|
if (stateMachine) {
|
|
32
26
|
stateMachine.registerSerializedSystem(this);
|
|
@@ -35,6 +29,9 @@ class SerializeStoredViewImp extends SerializeStoredView {
|
|
|
35
29
|
this.warn("Unable to find StateMachineEntity");
|
|
36
30
|
}
|
|
37
31
|
}
|
|
32
|
+
get storedView() {
|
|
33
|
+
return this.getCachedSingleton(StoredView_1.StoredView.type);
|
|
34
|
+
}
|
|
38
35
|
getSystemState() {
|
|
39
36
|
if (!this.storedView) {
|
|
40
37
|
console.warn("[SerializeStoredView] No stored view entity");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.makeSetViewInXRUC = exports.SetViewInXRUC = void 0;
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const Dispatcher_1 = require("../../Dispatcher");
|
|
6
6
|
class SetViewInXRUC extends AppObject_1.AppObjectUC {
|
|
@@ -12,16 +12,6 @@ function makeSetViewInXRUC(appObject) {
|
|
|
12
12
|
return new SetViewInXRUCImp(appObject);
|
|
13
13
|
}
|
|
14
14
|
exports.makeSetViewInXRUC = makeSetViewInXRUC;
|
|
15
|
-
function setViewInXR(appObjects) {
|
|
16
|
-
const uc = SetViewInXRUC.get(appObjects);
|
|
17
|
-
if (uc) {
|
|
18
|
-
uc.setViewInXR();
|
|
19
|
-
}
|
|
20
|
-
else {
|
|
21
|
-
appObjects.submitWarning("setViewInXR", "Can't find ClearStoredViewUC");
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
exports.setViewInXR = setViewInXR;
|
|
25
15
|
class SetViewInXRUCImp extends SetViewInXRUC {
|
|
26
16
|
constructor(appObject) {
|
|
27
17
|
super(appObject, SetViewInXRUC.type);
|
|
@@ -33,9 +23,8 @@ class SetViewInXRUCImp extends SetViewInXRUC {
|
|
|
33
23
|
this.warn("Missing necessary entities");
|
|
34
24
|
}
|
|
35
25
|
};
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
}
|
|
26
|
+
}
|
|
27
|
+
get dispatchStartZSpace() {
|
|
28
|
+
return this.getCachedSingleton(Dispatcher_1.DispatchStartZSpaceUC.type);
|
|
40
29
|
}
|
|
41
30
|
}
|
|
@@ -5,4 +5,3 @@ export declare abstract class StoreCurrentViewUC extends AppObjectUC {
|
|
|
5
5
|
abstract storeCurrentView(): void;
|
|
6
6
|
}
|
|
7
7
|
export declare function makeStoreCurrentViewUC(appObject: AppObject): StoreCurrentViewUC;
|
|
8
|
-
export declare function storeCurrentView(appObjects: AppObjectRepo): void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.makeStoreCurrentViewUC = exports.StoreCurrentViewUC = void 0;
|
|
4
4
|
const AppObject_1 = require("../../../AppObject");
|
|
5
5
|
const Dispatcher_1 = require("../../Dispatcher");
|
|
6
6
|
const SceneRoot_1 = require("../../SceneRoot");
|
|
@@ -14,16 +14,6 @@ function makeStoreCurrentViewUC(appObject) {
|
|
|
14
14
|
return new StoreCurrentViewUCImp(appObject);
|
|
15
15
|
}
|
|
16
16
|
exports.makeStoreCurrentViewUC = makeStoreCurrentViewUC;
|
|
17
|
-
function storeCurrentView(appObjects) {
|
|
18
|
-
const uc = StoreCurrentViewUC.get(appObjects);
|
|
19
|
-
if (uc) {
|
|
20
|
-
uc.storeCurrentView();
|
|
21
|
-
}
|
|
22
|
-
else {
|
|
23
|
-
appObjects.submitWarning("storeCurrentView", "Can't find StoreCurrentViewUC");
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
exports.storeCurrentView = storeCurrentView;
|
|
27
17
|
class StoreCurrentViewUCImp extends StoreCurrentViewUC {
|
|
28
18
|
constructor(appObject) {
|
|
29
19
|
super(appObject, StoreCurrentViewUC.type);
|
|
@@ -36,13 +26,11 @@ class StoreCurrentViewUCImp extends StoreCurrentViewUC {
|
|
|
36
26
|
this.storedView.hasStoredView = true;
|
|
37
27
|
Dispatcher_1.dispatchStateChange(this.appObject.appObjectRepo);
|
|
38
28
|
};
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
this.error("Unable to find stored view");
|
|
46
|
-
}
|
|
29
|
+
}
|
|
30
|
+
get storedView() {
|
|
31
|
+
return this.getCachedSingleton(Entities_1.StoredView.type);
|
|
32
|
+
}
|
|
33
|
+
get sceneRoot() {
|
|
34
|
+
return this.getCachedSingleton(SceneRoot_1.SceneRootEntity.type);
|
|
47
35
|
}
|
|
48
36
|
}
|
|
@@ -10,6 +10,9 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
10
10
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./Adapters"), exports);
|
|
14
|
+
__exportStar(require("./Controllers"), exports);
|
|
13
15
|
__exportStar(require("./Entities"), exports);
|
|
16
|
+
__exportStar(require("./Factories"), exports);
|
|
14
17
|
__exportStar(require("./PM"), exports);
|
|
15
18
|
__exportStar(require("./UC"), exports);
|
|
@@ -1,26 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.toolAdapter = void 0;
|
|
4
4
|
const ToolPM_1 = require("../PM/ToolPM");
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
return;
|
|
21
|
-
}
|
|
22
|
-
pm.removeView(setVM);
|
|
23
|
-
},
|
|
24
|
-
};
|
|
25
|
-
}
|
|
26
|
-
exports.makeToolAdapter = makeToolAdapter;
|
|
5
|
+
exports.toolAdapter = {
|
|
6
|
+
defaultVM: ToolPM_1.defaultToolVM,
|
|
7
|
+
subscribe: (id, appObjects, setVM) => {
|
|
8
|
+
const pm = ToolPM_1.ToolPM.get(id, appObjects);
|
|
9
|
+
if (!pm) {
|
|
10
|
+
appObjects.submitError("toolAdapter", "Unable to find ToolPM");
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
pm.addView(setVM);
|
|
14
|
+
},
|
|
15
|
+
unsubscribe: (id, appObjects, setVM) => {
|
|
16
|
+
var _a;
|
|
17
|
+
(_a = ToolPM_1.ToolPM.get(id, appObjects)) === null || _a === void 0 ? void 0 : _a.removeView(setVM);
|
|
18
|
+
},
|
|
19
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AppObject } from "../../../AppObject/AppObject";
|
|
2
2
|
import { AppObjectController } from "../../../AppObject/AppObjectController";
|
|
3
3
|
import { KeyboardController } from "../../KeyboardInput";
|
|
4
|
-
export declare class ToolHotkeys
|
|
4
|
+
export declare class ToolHotkeys extends AppObjectController implements KeyboardController {
|
|
5
5
|
static readonly type = "ToolHotkeys";
|
|
6
6
|
private toolRepo?;
|
|
7
7
|
onKeyDown: (e: KeyboardEvent) => void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { AppObjectRepo } from "../../../AppObject/AppObjectRepo";
|
|
2
|
-
export declare function triggerTool
|
|
2
|
+
export declare function triggerTool(toolType: string, appObjects: AppObjectRepo): void;
|
|
@@ -7,8 +7,8 @@ export declare enum ToolState {
|
|
|
7
7
|
ENABLED = "ENABLED",
|
|
8
8
|
ACTIVE = "ACTIVE"
|
|
9
9
|
}
|
|
10
|
-
export interface ToolData
|
|
11
|
-
toolType:
|
|
10
|
+
export interface ToolData {
|
|
11
|
+
toolType: string;
|
|
12
12
|
isDefault: boolean;
|
|
13
13
|
label: string;
|
|
14
14
|
shortcutLabel: string;
|
|
@@ -21,9 +21,9 @@ export interface HotKey {
|
|
|
21
21
|
meta?: boolean;
|
|
22
22
|
alt?: boolean;
|
|
23
23
|
}
|
|
24
|
-
export declare abstract class ToolEntity
|
|
24
|
+
export declare abstract class ToolEntity extends AppObjectEntity {
|
|
25
25
|
static readonly type = "TOOL";
|
|
26
|
-
abstract get toolType():
|
|
26
|
+
abstract get toolType(): string | undefined;
|
|
27
27
|
abstract get label(): string;
|
|
28
28
|
abstract set label(toolLabel: string);
|
|
29
29
|
abstract readonly isDefault: boolean;
|
|
@@ -36,7 +36,7 @@ export declare abstract class ToolEntity<ToolTypes> extends AppObjectEntity {
|
|
|
36
36
|
abstract triggerActions(): void;
|
|
37
37
|
abstract registerAction(action: () => void): void;
|
|
38
38
|
abstract isMyHotkey(hotkey: HotKey): boolean;
|
|
39
|
-
abstract setupFromData(data: ToolData
|
|
40
|
-
static get
|
|
39
|
+
abstract setupFromData(data: ToolData): void;
|
|
40
|
+
static get(id: string, appObjects: AppObjectRepo): ToolEntity | undefined;
|
|
41
41
|
}
|
|
42
|
-
export declare function makeToolEntity
|
|
42
|
+
export declare function makeToolEntity(appObject: AppObject): ToolEntity;
|
|
@@ -13,8 +13,7 @@ var ToolState;
|
|
|
13
13
|
class ToolEntity extends AppObjectEntity_1.AppObjectEntity {
|
|
14
14
|
static get(id, appObjects) {
|
|
15
15
|
var _a;
|
|
16
|
-
return (_a = appObjects
|
|
17
|
-
.get(id)) === null || _a === void 0 ? void 0 : _a.getComponent(ToolEntity.type);
|
|
16
|
+
return (_a = appObjects.get(id)) === null || _a === void 0 ? void 0 : _a.getComponent(ToolEntity.type);
|
|
18
17
|
}
|
|
19
18
|
}
|
|
20
19
|
exports.ToolEntity = ToolEntity;
|