@wcardinal/wcardinal-ui 0.200.1 → 0.201.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/dist/types/wcardinal/ui/{d-controller-default-command.d.ts → d-controller-command-impl.d.ts} +1 -1
- package/dist/types/wcardinal/ui/{d-controller-default-focus.d.ts → d-controller-focus-impl.d.ts} +1 -1
- package/dist/types/wcardinal/ui/d-diagram-canvas.d.ts +2 -3
- package/dist/types/wcardinal/ui/index.d.ts +2 -2
- package/dist/wcardinal/ui/d-application.js +2 -2
- package/dist/wcardinal/ui/d-application.js.map +1 -1
- package/dist/wcardinal/ui/d-base.js +2 -2
- package/dist/wcardinal/ui/d-base.js.map +1 -1
- package/dist/wcardinal/ui/{d-controller-default-command.js → d-controller-command-impl.js} +24 -24
- package/dist/wcardinal/ui/d-controller-command-impl.js.map +1 -0
- package/dist/wcardinal/ui/{d-controller-default-focus.js → d-controller-focus-impl.js} +20 -18
- package/dist/wcardinal/ui/d-controller-focus-impl.js.map +1 -0
- package/dist/wcardinal/ui/d-controllers.js +2 -2
- package/dist/wcardinal/ui/d-controllers.js.map +1 -1
- package/dist/wcardinal/ui/d-diagram-canvas.js +97 -98
- package/dist/wcardinal/ui/d-diagram-canvas.js.map +1 -1
- package/dist/wcardinal/ui/index.js +2 -2
- package/dist/wcardinal/ui/index.js.map +1 -1
- package/dist/wcardinal/ui/shape/e-shape-runtime.js +4 -2
- package/dist/wcardinal/ui/shape/e-shape-runtime.js.map +1 -1
- package/dist/wcardinal-ui-theme-dark.js +1 -1
- package/dist/wcardinal-ui-theme-dark.min.js +1 -1
- package/dist/wcardinal-ui-theme-white.js +1 -1
- package/dist/wcardinal-ui-theme-white.min.js +1 -1
- package/dist/wcardinal-ui.cjs.js +148 -145
- package/dist/wcardinal-ui.js +148 -145
- package/dist/wcardinal-ui.min.js +2 -2
- package/dist/wcardinal-ui.min.js.map +1 -1
- package/package.json +1 -1
- package/dist/wcardinal/ui/d-controller-default-command.js.map +0 -1
- package/dist/wcardinal/ui/d-controller-default-focus.js.map +0 -1
package/dist/wcardinal-ui.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Winter Cardinal UI v0.
|
|
2
|
+
Winter Cardinal UI v0.201.0
|
|
3
3
|
Copyright (C) 2019 Toshiba Corporation
|
|
4
4
|
SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
|
|
@@ -7833,15 +7833,17 @@
|
|
|
7833
7833
|
var data = shape.data;
|
|
7834
7834
|
var isEffectTimeUp = this.effect <= time;
|
|
7835
7835
|
if (data.isChanged || this.isStateChanged || isEffectTimeUp) {
|
|
7836
|
+
this.isStateChanged = false;
|
|
7837
|
+
data.isChanged = false;
|
|
7836
7838
|
if (isEffectTimeUp) {
|
|
7837
7839
|
this.effect = NaN;
|
|
7838
7840
|
}
|
|
7839
7841
|
shape.disallowUploadedUpdate();
|
|
7840
7842
|
this.onUpdate(shape, time);
|
|
7841
7843
|
shape.allowUploadedUpdate();
|
|
7844
|
+
var wasStateChanged = this.isStateChanged;
|
|
7842
7845
|
shape.state.removeAll(EShapeState.CLICKED, EShapeState.DOWN, EShapeState.UP, EShapeState.ACTIVATED, EShapeState.DEACTIVATED);
|
|
7843
|
-
this.isStateChanged =
|
|
7844
|
-
data.isChanged = false;
|
|
7846
|
+
this.isStateChanged = wasStateChanged;
|
|
7845
7847
|
}
|
|
7846
7848
|
};
|
|
7847
7849
|
EShapeRuntime.prototype.onRender = function (shape, time, renderer) {
|
|
@@ -13521,9 +13523,9 @@
|
|
|
13521
13523
|
if (target === this) {
|
|
13522
13524
|
return true;
|
|
13523
13525
|
}
|
|
13524
|
-
else if (target != null && !(target instanceof DBase)) {
|
|
13526
|
+
else if (target != null && !(target instanceof DBase && target.interactive)) {
|
|
13525
13527
|
var parent_5 = target.parent;
|
|
13526
|
-
while (parent_5 != null && !(parent_5 instanceof DBase)) {
|
|
13528
|
+
while (parent_5 != null && !(parent_5 instanceof DBase && parent_5.interactive)) {
|
|
13527
13529
|
parent_5 = parent_5.parent;
|
|
13528
13530
|
}
|
|
13529
13531
|
return parent_5 === this;
|
|
@@ -46295,9 +46297,9 @@
|
|
|
46295
46297
|
var isCommandClean = function (command) {
|
|
46296
46298
|
return !!(command.getFlag() & DCommandFlag.CLEAN);
|
|
46297
46299
|
};
|
|
46298
|
-
var
|
|
46299
|
-
__extends(
|
|
46300
|
-
function
|
|
46300
|
+
var DControllerCommandImpl = /** @class */ (function (_super) {
|
|
46301
|
+
__extends(DControllerCommandImpl, _super);
|
|
46302
|
+
function DControllerCommandImpl() {
|
|
46301
46303
|
var _this = _super.call(this) || this;
|
|
46302
46304
|
_this._position = 0;
|
|
46303
46305
|
_this._done = [];
|
|
@@ -46305,7 +46307,7 @@
|
|
|
46305
46307
|
_this._executing = null;
|
|
46306
46308
|
return _this;
|
|
46307
46309
|
}
|
|
46308
|
-
|
|
46310
|
+
DControllerCommandImpl.prototype.last = function () {
|
|
46309
46311
|
var done = this._done;
|
|
46310
46312
|
var waiting = this._waiting;
|
|
46311
46313
|
if (waiting.length <= 0) {
|
|
@@ -46320,11 +46322,11 @@
|
|
|
46320
46322
|
return waiting[waiting.length - 1];
|
|
46321
46323
|
}
|
|
46322
46324
|
};
|
|
46323
|
-
|
|
46325
|
+
DControllerCommandImpl.prototype.push = function (command) {
|
|
46324
46326
|
this._waiting.push(command);
|
|
46325
46327
|
this.next();
|
|
46326
46328
|
};
|
|
46327
|
-
|
|
46329
|
+
DControllerCommandImpl.prototype.next = function () {
|
|
46328
46330
|
if (this._executing != null) {
|
|
46329
46331
|
// Still executing a command.
|
|
46330
46332
|
// So do nothing.
|
|
@@ -46352,7 +46354,7 @@
|
|
|
46352
46354
|
this.execute(command);
|
|
46353
46355
|
}
|
|
46354
46356
|
};
|
|
46355
|
-
|
|
46357
|
+
DControllerCommandImpl.prototype.executeUndo = function (command) {
|
|
46356
46358
|
var _this = this;
|
|
46357
46359
|
var done = this._done;
|
|
46358
46360
|
if (this._position < done.length) {
|
|
@@ -46375,7 +46377,7 @@
|
|
|
46375
46377
|
}
|
|
46376
46378
|
}
|
|
46377
46379
|
};
|
|
46378
|
-
|
|
46380
|
+
DControllerCommandImpl.prototype.executeRedo = function (command) {
|
|
46379
46381
|
var _this = this;
|
|
46380
46382
|
var done = this._done;
|
|
46381
46383
|
if (0 < this._position) {
|
|
@@ -46398,7 +46400,7 @@
|
|
|
46398
46400
|
}
|
|
46399
46401
|
}
|
|
46400
46402
|
};
|
|
46401
|
-
|
|
46403
|
+
DControllerCommandImpl.prototype.execute = function (command) {
|
|
46402
46404
|
var _this = this;
|
|
46403
46405
|
var isClear = isCommandClear(command);
|
|
46404
46406
|
var isStorable = isCommandStorable(command);
|
|
@@ -46426,7 +46428,7 @@
|
|
|
46426
46428
|
});
|
|
46427
46429
|
}
|
|
46428
46430
|
};
|
|
46429
|
-
|
|
46431
|
+
DControllerCommandImpl.prototype.cleanup = function () {
|
|
46430
46432
|
var done = this._done;
|
|
46431
46433
|
var size = done.length - 100;
|
|
46432
46434
|
if (0 < size) {
|
|
@@ -46436,7 +46438,7 @@
|
|
|
46436
46438
|
}
|
|
46437
46439
|
}
|
|
46438
46440
|
};
|
|
46439
|
-
|
|
46441
|
+
DControllerCommandImpl.prototype.remove = function (size) {
|
|
46440
46442
|
var done = this._done;
|
|
46441
46443
|
if (0 < size) {
|
|
46442
46444
|
var ifrom = Math.max(0, done.length - size);
|
|
@@ -46451,7 +46453,7 @@
|
|
|
46451
46453
|
}
|
|
46452
46454
|
return false;
|
|
46453
46455
|
};
|
|
46454
|
-
|
|
46456
|
+
DControllerCommandImpl.prototype.onSuccess = function (command) {
|
|
46455
46457
|
this._executing = null;
|
|
46456
46458
|
if (isCommandStorable(command)) {
|
|
46457
46459
|
this._done.push(command);
|
|
@@ -46462,7 +46464,7 @@
|
|
|
46462
46464
|
this.emit("change", this);
|
|
46463
46465
|
this.next();
|
|
46464
46466
|
};
|
|
46465
|
-
|
|
46467
|
+
DControllerCommandImpl.prototype.onSuccessUndo = function (undoed) {
|
|
46466
46468
|
this._executing = null;
|
|
46467
46469
|
if (!isCommandClean(undoed)) {
|
|
46468
46470
|
this.emit("dirty", this);
|
|
@@ -46470,7 +46472,7 @@
|
|
|
46470
46472
|
this.emit("change", this);
|
|
46471
46473
|
this.next();
|
|
46472
46474
|
};
|
|
46473
|
-
|
|
46475
|
+
DControllerCommandImpl.prototype.onSuccessRedo = function (redoed) {
|
|
46474
46476
|
this._executing = null;
|
|
46475
46477
|
if (!isCommandClean(redoed)) {
|
|
46476
46478
|
this.emit("dirty", this);
|
|
@@ -46478,7 +46480,7 @@
|
|
|
46478
46480
|
this.emit("change", this);
|
|
46479
46481
|
this.next();
|
|
46480
46482
|
};
|
|
46481
|
-
|
|
46483
|
+
DControllerCommandImpl.prototype.onFail = function (command) {
|
|
46482
46484
|
this._executing = null;
|
|
46483
46485
|
var waiting = this._waiting;
|
|
46484
46486
|
command.destroy();
|
|
@@ -46488,31 +46490,31 @@
|
|
|
46488
46490
|
waiting.length = 0;
|
|
46489
46491
|
this.emit("change", this);
|
|
46490
46492
|
};
|
|
46491
|
-
|
|
46493
|
+
DControllerCommandImpl.prototype.size = function () {
|
|
46492
46494
|
return this._done.length;
|
|
46493
46495
|
};
|
|
46494
|
-
|
|
46496
|
+
DControllerCommandImpl.prototype.clear = function () {
|
|
46495
46497
|
this.push(new DCommandClear());
|
|
46496
46498
|
};
|
|
46497
|
-
|
|
46499
|
+
DControllerCommandImpl.prototype.redo = function () {
|
|
46498
46500
|
if (this.isRedoable()) {
|
|
46499
46501
|
this._waiting.push(new DCommandRedo());
|
|
46500
46502
|
this.next();
|
|
46501
46503
|
}
|
|
46502
46504
|
};
|
|
46503
|
-
|
|
46505
|
+
DControllerCommandImpl.prototype.undo = function () {
|
|
46504
46506
|
if (this.isUndoable()) {
|
|
46505
46507
|
this._waiting.push(new DCommandUndo());
|
|
46506
46508
|
this.next();
|
|
46507
46509
|
}
|
|
46508
46510
|
};
|
|
46509
|
-
|
|
46511
|
+
DControllerCommandImpl.prototype.isRedoable = function () {
|
|
46510
46512
|
return 0 < this._position && this._executing == null;
|
|
46511
46513
|
};
|
|
46512
|
-
|
|
46514
|
+
DControllerCommandImpl.prototype.isUndoable = function () {
|
|
46513
46515
|
return this._position < this._done.length && this._executing == null;
|
|
46514
46516
|
};
|
|
46515
|
-
return
|
|
46517
|
+
return DControllerCommandImpl;
|
|
46516
46518
|
}(pixi_js.utils.EventEmitter));
|
|
46517
46519
|
|
|
46518
46520
|
/*
|
|
@@ -46599,7 +46601,7 @@
|
|
|
46599
46601
|
// Command
|
|
46600
46602
|
DControllers.getCommandController = function () {
|
|
46601
46603
|
if (this.COMMAND == null) {
|
|
46602
|
-
this.COMMAND = new
|
|
46604
|
+
this.COMMAND = new DControllerCommandImpl();
|
|
46603
46605
|
}
|
|
46604
46606
|
return this.COMMAND;
|
|
46605
46607
|
};
|
|
@@ -46913,25 +46915,27 @@
|
|
|
46913
46915
|
* Copyright (C) 2019 Toshiba Corporation
|
|
46914
46916
|
* SPDX-License-Identifier: Apache-2.0
|
|
46915
46917
|
*/
|
|
46916
|
-
var
|
|
46917
|
-
function
|
|
46918
|
+
var DControllerFocusImpl = /** @class */ (function () {
|
|
46919
|
+
function DControllerFocusImpl() {
|
|
46918
46920
|
this._focused = null;
|
|
46919
46921
|
}
|
|
46920
|
-
|
|
46922
|
+
DControllerFocusImpl.prototype.focus = function (focusable) {
|
|
46921
46923
|
var previous = this._focused;
|
|
46922
46924
|
if (previous !== focusable) {
|
|
46923
46925
|
if (previous != null) {
|
|
46926
|
+
console.log("previous", previous.constructor.name);
|
|
46924
46927
|
previous.state.isFocused = false;
|
|
46925
46928
|
}
|
|
46926
46929
|
this._focused = focusable;
|
|
46927
46930
|
if (this.isFocusable(focusable)) {
|
|
46931
|
+
console.log("previous", focusable.constructor.name);
|
|
46928
46932
|
focusable.state.isFocused = true;
|
|
46929
46933
|
}
|
|
46930
46934
|
return previous;
|
|
46931
46935
|
}
|
|
46932
46936
|
return null;
|
|
46933
46937
|
};
|
|
46934
|
-
|
|
46938
|
+
DControllerFocusImpl.prototype.blur = function (focusable) {
|
|
46935
46939
|
if (focusable != null && this._focused === focusable) {
|
|
46936
46940
|
this._focused = null;
|
|
46937
46941
|
focusable.state.isFocused = false;
|
|
@@ -46939,10 +46943,10 @@
|
|
|
46939
46943
|
}
|
|
46940
46944
|
return null;
|
|
46941
46945
|
};
|
|
46942
|
-
|
|
46946
|
+
DControllerFocusImpl.prototype.clear = function () {
|
|
46943
46947
|
return this.focus(null);
|
|
46944
46948
|
};
|
|
46945
|
-
|
|
46949
|
+
DControllerFocusImpl.prototype.set = function (focusable, isFocused) {
|
|
46946
46950
|
if (isFocused) {
|
|
46947
46951
|
return this.focus(focusable);
|
|
46948
46952
|
}
|
|
@@ -46950,10 +46954,10 @@
|
|
|
46950
46954
|
return this.blur(focusable);
|
|
46951
46955
|
}
|
|
46952
46956
|
};
|
|
46953
|
-
|
|
46957
|
+
DControllerFocusImpl.prototype.get = function () {
|
|
46954
46958
|
return this._focused;
|
|
46955
46959
|
};
|
|
46956
|
-
|
|
46960
|
+
DControllerFocusImpl.prototype.findParent = function (mightBeFocusable) {
|
|
46957
46961
|
var current = mightBeFocusable;
|
|
46958
46962
|
while (current != null) {
|
|
46959
46963
|
if (this.isFocusable(current)) {
|
|
@@ -46965,7 +46969,7 @@
|
|
|
46965
46969
|
}
|
|
46966
46970
|
return null;
|
|
46967
46971
|
};
|
|
46968
|
-
|
|
46972
|
+
DControllerFocusImpl.prototype.find = function (target, includesTarget, includesTargetChildren, direction, root) {
|
|
46969
46973
|
if (direction) {
|
|
46970
46974
|
var result = this.findNext(target, includesTarget, includesTargetChildren);
|
|
46971
46975
|
if (result != null) {
|
|
@@ -47079,7 +47083,7 @@
|
|
|
47079
47083
|
}
|
|
47080
47084
|
return null;
|
|
47081
47085
|
};
|
|
47082
|
-
|
|
47086
|
+
DControllerFocusImpl.prototype.findNext = function (target, includesTarget, includesTargetChildren) {
|
|
47083
47087
|
// Target itself
|
|
47084
47088
|
if (includesTarget) {
|
|
47085
47089
|
if (this.isFocusable(target)) {
|
|
@@ -47110,7 +47114,7 @@
|
|
|
47110
47114
|
// Found nothing
|
|
47111
47115
|
return null;
|
|
47112
47116
|
};
|
|
47113
|
-
|
|
47117
|
+
DControllerFocusImpl.prototype.findPrevious = function (target, includesTarget, includesTargetChildren) {
|
|
47114
47118
|
// Target children
|
|
47115
47119
|
if (includesTargetChildren && this.isFocusableContainer(target) && target.visible) {
|
|
47116
47120
|
var children = target.children;
|
|
@@ -47141,26 +47145,26 @@
|
|
|
47141
47145
|
// Found nothing
|
|
47142
47146
|
return null;
|
|
47143
47147
|
};
|
|
47144
|
-
|
|
47148
|
+
DControllerFocusImpl.prototype.isFocusable = function (target) {
|
|
47145
47149
|
return (target != null &&
|
|
47146
47150
|
"state" in target &&
|
|
47147
47151
|
target.state.inEnabled &&
|
|
47148
47152
|
target.state.isFocusable &&
|
|
47149
47153
|
target.visible);
|
|
47150
47154
|
};
|
|
47151
|
-
|
|
47155
|
+
DControllerFocusImpl.prototype.isFocusableContainer = function (target) {
|
|
47152
47156
|
return target != null && "children" in target;
|
|
47153
47157
|
};
|
|
47154
|
-
|
|
47158
|
+
DControllerFocusImpl.prototype.isFocusRoot = function (target, root) {
|
|
47155
47159
|
if (target === root) {
|
|
47156
47160
|
return true;
|
|
47157
47161
|
}
|
|
47158
47162
|
return target != null && "state" in target && target.state.isFocusRoot && target.visible;
|
|
47159
47163
|
};
|
|
47160
|
-
|
|
47164
|
+
DControllerFocusImpl.prototype.isFocusReverse = function (target) {
|
|
47161
47165
|
return target != null && "state" in target && target.state.isFocusReverse;
|
|
47162
47166
|
};
|
|
47163
|
-
return
|
|
47167
|
+
return DControllerFocusImpl;
|
|
47164
47168
|
}());
|
|
47165
47169
|
|
|
47166
47170
|
/*
|
|
@@ -47242,7 +47246,7 @@
|
|
|
47242
47246
|
};
|
|
47243
47247
|
DApplication.prototype.getFocusController = function () {
|
|
47244
47248
|
if (this._focus == null) {
|
|
47245
|
-
this._focus = new
|
|
47249
|
+
this._focus = new DControllerFocusImpl();
|
|
47246
47250
|
}
|
|
47247
47251
|
return this._focus;
|
|
47248
47252
|
};
|
|
@@ -59139,7 +59143,7 @@
|
|
|
59139
59143
|
DDiagramCanvas.prototype.initialize = function (shapes, mapper) {
|
|
59140
59144
|
var time = Date.now();
|
|
59141
59145
|
var actionables = this._actionables;
|
|
59142
|
-
this.initialize_(shapes, null, mapper, new Map(), new Map(), new Map(), this._ticker, this._shape, this._data, actionables);
|
|
59146
|
+
this.initialize_(shapes, null, null, mapper, new Map(), new Map(), new Map(), this._ticker, this._shape, this._data, actionables);
|
|
59143
59147
|
var layers = this._layer.children;
|
|
59144
59148
|
for (var i = 0, imax = layers.length; i < imax; ++i) {
|
|
59145
59149
|
layers[i].initialize(actionables);
|
|
@@ -59154,7 +59158,7 @@
|
|
|
59154
59158
|
EShapeActionEnvironment.isInitializing = false;
|
|
59155
59159
|
this._ticker.start();
|
|
59156
59160
|
};
|
|
59157
|
-
DDiagramCanvas.prototype.initialize_ = function (shapes, dataShape, mapper, formatToFormatter, initialToInitialValue, actionValueToRuntime, canvasTicker, canvasShape, canvasData, actionables) {
|
|
59161
|
+
DDiagramCanvas.prototype.initialize_ = function (shapes, dataShape, containerShape, mapper, formatToFormatter, initialToInitialValue, actionValueToRuntime, canvasTicker, canvasShape, canvasData, actionables) {
|
|
59158
59162
|
var _loop_1 = function (i, imax) {
|
|
59159
59163
|
var shape = shapes[i];
|
|
59160
59164
|
// ID
|
|
@@ -59163,7 +59167,7 @@
|
|
|
59163
59167
|
canvasShape.add(id, shape);
|
|
59164
59168
|
}
|
|
59165
59169
|
// Data
|
|
59166
|
-
this_1.initData(shape, dataShape, mapper, formatToFormatter, initialToInitialValue, canvasTicker, canvasData);
|
|
59170
|
+
this_1.initData(shape, dataShape, containerShape, mapper, formatToFormatter, initialToInitialValue, canvasTicker, canvasData);
|
|
59167
59171
|
// Runtime
|
|
59168
59172
|
var runtime = new (EShapeRuntimes[shape.type] || EShapeRuntime)(shape);
|
|
59169
59173
|
shape.runtime = runtime;
|
|
@@ -59185,7 +59189,13 @@
|
|
|
59185
59189
|
// Children
|
|
59186
59190
|
var children = shape.children;
|
|
59187
59191
|
if (0 < children.length) {
|
|
59188
|
-
|
|
59192
|
+
if (shape instanceof EShapeEmbedded) {
|
|
59193
|
+
if (dataShape == null) {
|
|
59194
|
+
dataShape = shape;
|
|
59195
|
+
}
|
|
59196
|
+
containerShape = shape;
|
|
59197
|
+
}
|
|
59198
|
+
this_1.initialize_(children, dataShape, containerShape, mapper, formatToFormatter, initialToInitialValue, actionValueToRuntime, canvasTicker, canvasShape, canvasData, actionables);
|
|
59189
59199
|
}
|
|
59190
59200
|
};
|
|
59191
59201
|
var this_1 = this;
|
|
@@ -59193,105 +59203,107 @@
|
|
|
59193
59203
|
_loop_1(i);
|
|
59194
59204
|
}
|
|
59195
59205
|
};
|
|
59196
|
-
DDiagramCanvas.prototype.initData = function (shape, dataShape, mapper, formatToFormatter, initialToInitialValue, canvasTicker, canvasData) {
|
|
59206
|
+
DDiagramCanvas.prototype.initData = function (shape, dataShape, containerShape, mapper, formatToFormatter, initialToInitialValue, canvasTicker, canvasData) {
|
|
59197
59207
|
var data = shape.data;
|
|
59208
|
+
var format = "";
|
|
59209
|
+
var initial = "";
|
|
59198
59210
|
for (var i = 0, imax = data.size(); i < imax; ++i) {
|
|
59199
59211
|
var value = data.get(i);
|
|
59200
|
-
if (value)
|
|
59201
|
-
|
|
59202
|
-
|
|
59203
|
-
|
|
59204
|
-
|
|
59205
|
-
|
|
59206
|
-
|
|
59207
|
-
|
|
59208
|
-
|
|
59209
|
-
|
|
59210
|
-
|
|
59211
|
-
|
|
59212
|
-
if (
|
|
59213
|
-
|
|
59214
|
-
|
|
59215
|
-
if (dataShape) {
|
|
59216
|
-
dataShape.data.private.add(id, value);
|
|
59217
|
-
}
|
|
59218
|
-
else {
|
|
59219
|
-
canvasData.private.add(id, value);
|
|
59220
|
-
}
|
|
59212
|
+
if (value == null)
|
|
59213
|
+
continue;
|
|
59214
|
+
switch (value.type) {
|
|
59215
|
+
case EShapeDataValueType.NUMBER:
|
|
59216
|
+
case EShapeDataValueType.NUMBER_ARRAY:
|
|
59217
|
+
case EShapeDataValueType.STRING:
|
|
59218
|
+
case EShapeDataValueType.STRING_ARRAY:
|
|
59219
|
+
case EShapeDataValueType.OBJECT:
|
|
59220
|
+
case EShapeDataValueType.OBJECT_ARRAY:
|
|
59221
|
+
// Mapping
|
|
59222
|
+
if (value.scope === EShapeDataValueScope.PRIVATE) {
|
|
59223
|
+
var id = value.id;
|
|
59224
|
+
if (0 < id.length) {
|
|
59225
|
+
if (containerShape) {
|
|
59226
|
+
containerShape.data.private.add(id, value);
|
|
59221
59227
|
}
|
|
59222
|
-
|
|
59223
|
-
|
|
59224
|
-
var id = value.id;
|
|
59225
|
-
if (0 < id.length) {
|
|
59226
|
-
canvasData.protected.add(id, value);
|
|
59228
|
+
else {
|
|
59229
|
+
canvasData.private.add(id, value);
|
|
59227
59230
|
}
|
|
59228
59231
|
}
|
|
59229
|
-
|
|
59230
|
-
|
|
59231
|
-
|
|
59232
|
-
|
|
59233
|
-
|
|
59234
|
-
if (0 < id.length) {
|
|
59235
|
-
canvasData.add(id, value);
|
|
59236
|
-
}
|
|
59232
|
+
}
|
|
59233
|
+
else if (value.scope === EShapeDataValueScope.PROTECTED) {
|
|
59234
|
+
var id = value.id;
|
|
59235
|
+
if (0 < id.length) {
|
|
59236
|
+
canvasData.protected.add(id, value);
|
|
59237
59237
|
}
|
|
59238
|
-
|
|
59239
|
-
|
|
59240
|
-
|
|
59238
|
+
}
|
|
59239
|
+
else {
|
|
59240
|
+
if (mapper) {
|
|
59241
|
+
mapper(value, dataShape || shape);
|
|
59241
59242
|
}
|
|
59242
|
-
|
|
59243
|
-
|
|
59244
|
-
|
|
59245
|
-
formatToFormatter.set(format, formatter);
|
|
59246
|
-
value.formatter = formatter;
|
|
59247
|
-
}
|
|
59248
|
-
catch (e) {
|
|
59249
|
-
// DO NOTHING
|
|
59250
|
-
}
|
|
59243
|
+
var id = value.id;
|
|
59244
|
+
if (0 < id.length) {
|
|
59245
|
+
canvasData.add(id, value);
|
|
59251
59246
|
}
|
|
59252
|
-
|
|
59253
|
-
|
|
59254
|
-
|
|
59247
|
+
}
|
|
59248
|
+
// Format
|
|
59249
|
+
format = value.format;
|
|
59250
|
+
initial = value.initial;
|
|
59251
|
+
if (formatToFormatter.has(format)) {
|
|
59252
|
+
value.formatter = formatToFormatter.get(format);
|
|
59253
|
+
}
|
|
59254
|
+
else if (0 < format.length) {
|
|
59255
|
+
try {
|
|
59256
|
+
var formatter = this.calcFormatter(value, format, initial);
|
|
59257
|
+
formatToFormatter.set(format, formatter);
|
|
59258
|
+
value.formatter = formatter;
|
|
59255
59259
|
}
|
|
59256
|
-
|
|
59257
|
-
|
|
59258
|
-
var initialValue = this.calcInitial(value, initial);
|
|
59259
|
-
initialToInitialValue.set(initial, initialValue);
|
|
59260
|
-
value.value = initialValue;
|
|
59261
|
-
}
|
|
59262
|
-
catch (e) {
|
|
59263
|
-
// DO NOTHING
|
|
59264
|
-
}
|
|
59260
|
+
catch (e) {
|
|
59261
|
+
// DO NOTHING
|
|
59265
59262
|
}
|
|
59266
|
-
|
|
59267
|
-
|
|
59268
|
-
|
|
59269
|
-
|
|
59270
|
-
|
|
59271
|
-
|
|
59263
|
+
}
|
|
59264
|
+
// Initial
|
|
59265
|
+
if (initialToInitialValue.has(initial)) {
|
|
59266
|
+
value.value = initialToInitialValue.get(initial);
|
|
59267
|
+
}
|
|
59268
|
+
else if (0 < initial.length) {
|
|
59269
|
+
try {
|
|
59270
|
+
var initialValue = this.calcInitial(value, initial);
|
|
59271
|
+
initialToInitialValue.set(initial, initialValue);
|
|
59272
|
+
value.value = initialValue;
|
|
59272
59273
|
}
|
|
59273
|
-
|
|
59274
|
-
|
|
59275
|
-
var initialValue = this.calcInitial(value, initial);
|
|
59276
|
-
initialToInitialValue.set(initial, initialValue);
|
|
59277
|
-
value.value = 0;
|
|
59278
|
-
canvasTicker.add(initialValue).add(value);
|
|
59279
|
-
}
|
|
59280
|
-
catch (e) {
|
|
59281
|
-
// DO NOTHING
|
|
59282
|
-
}
|
|
59274
|
+
catch (e) {
|
|
59275
|
+
// DO NOTHING
|
|
59283
59276
|
}
|
|
59284
|
-
|
|
59285
|
-
|
|
59286
|
-
|
|
59287
|
-
|
|
59288
|
-
|
|
59289
|
-
|
|
59290
|
-
|
|
59291
|
-
|
|
59277
|
+
}
|
|
59278
|
+
break;
|
|
59279
|
+
case EShapeDataValueType.TICKER:
|
|
59280
|
+
// Initial
|
|
59281
|
+
initial = value.initial;
|
|
59282
|
+
if (initialToInitialValue.has(initial)) {
|
|
59283
|
+
value.value = 0;
|
|
59284
|
+
canvasTicker.add(initialToInitialValue.get(initial)).add(value);
|
|
59285
|
+
}
|
|
59286
|
+
else if (0 < initial.length) {
|
|
59287
|
+
try {
|
|
59288
|
+
var initialValue = this.calcInitial(value, initial);
|
|
59289
|
+
initialToInitialValue.set(initial, initialValue);
|
|
59290
|
+
value.value = 0;
|
|
59291
|
+
canvasTicker.add(initialValue).add(value);
|
|
59292
59292
|
}
|
|
59293
|
-
|
|
59294
|
-
|
|
59293
|
+
catch (e) {
|
|
59294
|
+
// DO NOTHING
|
|
59295
|
+
}
|
|
59296
|
+
}
|
|
59297
|
+
break;
|
|
59298
|
+
default:
|
|
59299
|
+
var extension = EShapeDataValueExtensions.get(value.type);
|
|
59300
|
+
if (extension) {
|
|
59301
|
+
// Mapping
|
|
59302
|
+
canvasData.extended.add(extension.id, value);
|
|
59303
|
+
// Initial
|
|
59304
|
+
value.value = extension.initial;
|
|
59305
|
+
}
|
|
59306
|
+
break;
|
|
59295
59307
|
}
|
|
59296
59308
|
}
|
|
59297
59309
|
};
|
|
@@ -59363,15 +59375,6 @@
|
|
|
59363
59375
|
return "0";
|
|
59364
59376
|
}
|
|
59365
59377
|
};
|
|
59366
|
-
DDiagramCanvas.prototype.toDataShape = function (dataShape, shape) {
|
|
59367
|
-
if (dataShape != null) {
|
|
59368
|
-
return dataShape;
|
|
59369
|
-
}
|
|
59370
|
-
if (shape instanceof EShapeEmbedded) {
|
|
59371
|
-
return shape;
|
|
59372
|
-
}
|
|
59373
|
-
return null;
|
|
59374
|
-
};
|
|
59375
59378
|
DDiagramCanvas.prototype.onDestroy = function () {
|
|
59376
59379
|
this._ticker.stop();
|
|
59377
59380
|
_super.prototype.onDestroy.call(this);
|
|
@@ -71732,8 +71735,8 @@
|
|
|
71732
71735
|
DCommandSave: DCommandSave,
|
|
71733
71736
|
DCommandUndo: DCommandUndo,
|
|
71734
71737
|
DContent: DContent,
|
|
71735
|
-
|
|
71736
|
-
|
|
71738
|
+
DControllerCommandImpl: DControllerCommandImpl,
|
|
71739
|
+
DControllerFocusImpl: DControllerFocusImpl,
|
|
71737
71740
|
DControllerKeyboard: DControllerKeyboard,
|
|
71738
71741
|
DControllers: DControllers,
|
|
71739
71742
|
DCornerMask: DCornerMask,
|