@wcardinal/wcardinal-ui 0.341.0 → 0.342.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/shape/e-shape-acceptors.d.ts +7 -4
- package/dist/types/wcardinal/ui/shape/e-shape-capability.d.ts +1 -0
- package/dist/types/wcardinal/ui/shape/e-shape-type.d.ts +1 -0
- package/dist/types/wcardinal/ui/shape/variant/deserialize-embedded-acceptor-edge.d.ts +4 -0
- package/dist/types/wcardinal/ui/shape/variant/e-shape-embedded-acceptor-edge.d.ts +29 -0
- package/dist/types/wcardinal/ui/shape/variant/e-shape-embedded-acceptor.d.ts +8 -0
- package/dist/types/wcardinal/ui/shape/variant/e-shape-embedded.d.ts +7 -0
- package/dist/types/wcardinal/ui/shape/variant/index.d.ts +3 -1
- package/dist/wcardinal/ui/shape/e-shape-acceptors.js +48 -14
- package/dist/wcardinal/ui/shape/e-shape-acceptors.js.map +1 -1
- package/dist/wcardinal/ui/shape/e-shape-capability.js +2 -0
- package/dist/wcardinal/ui/shape/e-shape-capability.js.map +1 -1
- package/dist/wcardinal/ui/shape/e-shape-type.js +1 -0
- package/dist/wcardinal/ui/shape/e-shape-type.js.map +1 -1
- package/dist/wcardinal/ui/shape/load/load-shape-embedded.js +8 -0
- package/dist/wcardinal/ui/shape/load/load-shape-embedded.js.map +1 -1
- package/dist/wcardinal/ui/shape/variant/deserialize-embedded-acceptor-edge.js +37 -0
- package/dist/wcardinal/ui/shape/variant/deserialize-embedded-acceptor-edge.js.map +1 -0
- package/dist/wcardinal/ui/shape/variant/e-shape-embedded-acceptor-edge.js +71 -0
- package/dist/wcardinal/ui/shape/variant/e-shape-embedded-acceptor-edge.js.map +1 -0
- package/dist/wcardinal/ui/shape/variant/e-shape-embedded-acceptor.js +37 -0
- package/dist/wcardinal/ui/shape/variant/e-shape-embedded-acceptor.js.map +1 -0
- package/dist/wcardinal/ui/shape/variant/e-shape-embedded.js +66 -0
- package/dist/wcardinal/ui/shape/variant/e-shape-embedded.js.map +1 -1
- package/dist/wcardinal/ui/shape/variant/index.js +3 -1
- package/dist/wcardinal/ui/shape/variant/index.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 +297 -60
- package/dist/wcardinal-ui.js +298 -61
- 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.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Winter Cardinal UI v0.
|
|
2
|
+
Winter Cardinal UI v0.342.0
|
|
3
3
|
Copyright (C) 2019 Toshiba Corporation
|
|
4
4
|
SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
|
|
@@ -52,6 +52,7 @@
|
|
|
52
52
|
CONNECTOR_LINE: 22,
|
|
53
53
|
CONNECTOR_ELBOW: 23,
|
|
54
54
|
SEMICIRCLE: 24,
|
|
55
|
+
EMBEDDED_ACCEPTOR_EDGE: 25,
|
|
55
56
|
EXTENSION: 1000
|
|
56
57
|
};
|
|
57
58
|
|
|
@@ -4470,6 +4471,7 @@
|
|
|
4470
4471
|
var PRIMITIVE = ID | COORDINATE | SHAPE | TEXT$2 | TEXTURE | DATA | ACTION | CURSOR$1 | LAYER | CHILDREN$1;
|
|
4471
4472
|
var GROUP = PRIMITIVE | UNGROUPING;
|
|
4472
4473
|
var EMBEDDED = ID | COORDINATE | REPLACING | GROUPING | TEXT$2 | DATA | ACTION | LAYER | DATA_MAPPING;
|
|
4474
|
+
var EMBEDDED_ACCEPTOR_EDGE = ID | COORDINATE | REPLACING | FILL$1 | STROKE$1 | TEXT$2 | TEXTURE | DATA | ACTION | CURSOR$1 | LAYER;
|
|
4473
4475
|
var CONNECTOR = ID | REPLACING | FILL$1 | STROKE$1 | LINE | LINE_TAIL | LINE_HEAD | TEXT$2 | TEXTURE | DATA | ACTION | CURSOR$1 | LAYER | CHILDREN$1;
|
|
4474
4476
|
var ALL = PRIMITIVE | STROKE_SIDE | BORDER_RADIUS | DATA_MAPPING | UNGROUPING;
|
|
4475
4477
|
var EShapeCapability = {
|
|
@@ -4580,6 +4582,7 @@
|
|
|
4580
4582
|
PRIMITIVE: PRIMITIVE,
|
|
4581
4583
|
GROUP: GROUP,
|
|
4582
4584
|
EMBEDDED: EMBEDDED,
|
|
4585
|
+
EMBEDDED_ACCEPTOR_EDGE: EMBEDDED_ACCEPTOR_EDGE,
|
|
4583
4586
|
CONNECTOR: CONNECTOR,
|
|
4584
4587
|
ALL: ALL
|
|
4585
4588
|
};
|
|
@@ -16725,6 +16728,115 @@
|
|
|
16725
16728
|
EDITOR: 2
|
|
16726
16729
|
};
|
|
16727
16730
|
|
|
16731
|
+
/*
|
|
16732
|
+
* Copyright (C) 2019 Toshiba Corporation
|
|
16733
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
16734
|
+
*/
|
|
16735
|
+
var EShapeAcceptorEdgeSide = {
|
|
16736
|
+
NONE: 0,
|
|
16737
|
+
TOP: 1,
|
|
16738
|
+
RIGHT: 2,
|
|
16739
|
+
BOTTOM: 4,
|
|
16740
|
+
LEFT: 8,
|
|
16741
|
+
ALL: 15
|
|
16742
|
+
};
|
|
16743
|
+
|
|
16744
|
+
/*
|
|
16745
|
+
* Copyright (C) 2019 Toshiba Corporation
|
|
16746
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
16747
|
+
*/
|
|
16748
|
+
var EShapeAcceptorEdgeType = {
|
|
16749
|
+
TAIL: 1,
|
|
16750
|
+
HEAD: 2,
|
|
16751
|
+
ALL: 3
|
|
16752
|
+
};
|
|
16753
|
+
|
|
16754
|
+
/*
|
|
16755
|
+
* Copyright (C) 2019 Toshiba Corporation
|
|
16756
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
16757
|
+
*/
|
|
16758
|
+
var EShapeCircle = /** @class */ (function (_super) {
|
|
16759
|
+
__extends(EShapeCircle, _super);
|
|
16760
|
+
function EShapeCircle(type) {
|
|
16761
|
+
if (type === void 0) { type = EShapeType.CIRCLE; }
|
|
16762
|
+
return _super.call(this, type) || this;
|
|
16763
|
+
}
|
|
16764
|
+
EShapeCircle.prototype.clone = function () {
|
|
16765
|
+
return new EShapeCircle(this.type).copy(this);
|
|
16766
|
+
};
|
|
16767
|
+
EShapeCircle.prototype.containsAbs = function (x, y, ax, ay, sw, ss, sa) {
|
|
16768
|
+
if (_super.prototype.containsAbsBBox.call(this, x, y, ax, ay)) {
|
|
16769
|
+
return hitTestCircle(this, x, y, ax, ay, sw, ss);
|
|
16770
|
+
}
|
|
16771
|
+
return false;
|
|
16772
|
+
};
|
|
16773
|
+
return EShapeCircle;
|
|
16774
|
+
}(EShapePrimitive));
|
|
16775
|
+
|
|
16776
|
+
var EShapeEmbeddedAcceptorEdge = /** @class */ (function (_super) {
|
|
16777
|
+
__extends(EShapeEmbeddedAcceptorEdge, _super);
|
|
16778
|
+
function EShapeEmbeddedAcceptorEdge(type) {
|
|
16779
|
+
if (type === void 0) { type = EShapeType.EMBEDDED_ACCEPTOR_EDGE; }
|
|
16780
|
+
var _this = _super.call(this, type) || this;
|
|
16781
|
+
_this._subtype = EShapeAcceptorEdgeType.HEAD;
|
|
16782
|
+
_this._side = EShapeAcceptorEdgeSide.ALL;
|
|
16783
|
+
_this._vvisible = true;
|
|
16784
|
+
return _this;
|
|
16785
|
+
}
|
|
16786
|
+
Object.defineProperty(EShapeEmbeddedAcceptorEdge.prototype, "subtype", {
|
|
16787
|
+
get: function () {
|
|
16788
|
+
return this._subtype;
|
|
16789
|
+
},
|
|
16790
|
+
set: function (subtype) {
|
|
16791
|
+
this._subtype = subtype;
|
|
16792
|
+
},
|
|
16793
|
+
enumerable: false,
|
|
16794
|
+
configurable: true
|
|
16795
|
+
});
|
|
16796
|
+
Object.defineProperty(EShapeEmbeddedAcceptorEdge.prototype, "side", {
|
|
16797
|
+
get: function () {
|
|
16798
|
+
return this._side;
|
|
16799
|
+
},
|
|
16800
|
+
set: function (side) {
|
|
16801
|
+
this._side = side;
|
|
16802
|
+
},
|
|
16803
|
+
enumerable: false,
|
|
16804
|
+
configurable: true
|
|
16805
|
+
});
|
|
16806
|
+
Object.defineProperty(EShapeEmbeddedAcceptorEdge.prototype, "vvisible", {
|
|
16807
|
+
/**
|
|
16808
|
+
* True if visible in the viewer mode.
|
|
16809
|
+
*/
|
|
16810
|
+
get: function () {
|
|
16811
|
+
return this._vvisible;
|
|
16812
|
+
},
|
|
16813
|
+
set: function (vvisible) {
|
|
16814
|
+
this._vvisible = vvisible;
|
|
16815
|
+
},
|
|
16816
|
+
enumerable: false,
|
|
16817
|
+
configurable: true
|
|
16818
|
+
});
|
|
16819
|
+
EShapeEmbeddedAcceptorEdge.prototype.clone = function () {
|
|
16820
|
+
return new EShapeEmbeddedAcceptorEdge(this.type).copy(this);
|
|
16821
|
+
};
|
|
16822
|
+
EShapeEmbeddedAcceptorEdge.prototype.copy = function (source, part) {
|
|
16823
|
+
if (part === void 0) { part = EShapeCopyPart.ALL; }
|
|
16824
|
+
_super.prototype.copy.call(this, source, part);
|
|
16825
|
+
if (source instanceof EShapeEmbeddedAcceptorEdge) {
|
|
16826
|
+
this._subtype = source.subtype;
|
|
16827
|
+
this._side = source.side;
|
|
16828
|
+
this._vvisible = source.vvisible;
|
|
16829
|
+
}
|
|
16830
|
+
return this;
|
|
16831
|
+
};
|
|
16832
|
+
EShapeEmbeddedAcceptorEdge.prototype.serialize = function (manager) {
|
|
16833
|
+
var result = _super.prototype.serialize.call(this, manager);
|
|
16834
|
+
result[15] = this._subtype + (this._side << 2) + (this._vvisible ? 1 << 6 : 0);
|
|
16835
|
+
return result;
|
|
16836
|
+
};
|
|
16837
|
+
return EShapeEmbeddedAcceptorEdge;
|
|
16838
|
+
}(EShapeCircle));
|
|
16839
|
+
|
|
16728
16840
|
/*
|
|
16729
16841
|
* Copyright (C) 2019 Toshiba Corporation
|
|
16730
16842
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -17582,6 +17694,71 @@
|
|
|
17582
17694
|
enumerable: false,
|
|
17583
17695
|
configurable: true
|
|
17584
17696
|
});
|
|
17697
|
+
Object.defineProperty(EShapeEmbedded.prototype, "edges", {
|
|
17698
|
+
get: function () {
|
|
17699
|
+
var _a;
|
|
17700
|
+
return ((_a = this._edges) !== null && _a !== void 0 ? _a : (this._edges = this.newEdges()));
|
|
17701
|
+
},
|
|
17702
|
+
enumerable: false,
|
|
17703
|
+
configurable: true
|
|
17704
|
+
});
|
|
17705
|
+
EShapeEmbedded.prototype.newEdges = function () {
|
|
17706
|
+
var result = new Map();
|
|
17707
|
+
var layers = this.children;
|
|
17708
|
+
if (layers != null) {
|
|
17709
|
+
var s = this.size;
|
|
17710
|
+
var sx = s.x;
|
|
17711
|
+
var sy = s.y;
|
|
17712
|
+
var sxh = sx * 0.5;
|
|
17713
|
+
var syh = sy * 0.5;
|
|
17714
|
+
for (var i = 0, imax = layers.length; i < imax; ++i) {
|
|
17715
|
+
var layer = layers[i];
|
|
17716
|
+
var lp = layer.transform.position;
|
|
17717
|
+
var lpx = lp.x;
|
|
17718
|
+
var lpy = lp.y;
|
|
17719
|
+
var children = layer.children;
|
|
17720
|
+
for (var j = 0, jmax = children.length; j < jmax; ++j) {
|
|
17721
|
+
var child = children[j];
|
|
17722
|
+
if (child instanceof EShapeEmbeddedAcceptorEdge) {
|
|
17723
|
+
child.transform.updateLocalTransform();
|
|
17724
|
+
var clt = child.transform.localTransform;
|
|
17725
|
+
result.set(child.id, {
|
|
17726
|
+
type: child.subtype,
|
|
17727
|
+
x: this.toEedgePosition(lpx, clt.tx, sxh, sx),
|
|
17728
|
+
y: this.toEedgePosition(lpy, clt.ty, syh, sy),
|
|
17729
|
+
normal: this.toEedgeNormal(clt.c, clt.d),
|
|
17730
|
+
size: {
|
|
17731
|
+
x: 0,
|
|
17732
|
+
y: 0
|
|
17733
|
+
},
|
|
17734
|
+
side: child.side
|
|
17735
|
+
});
|
|
17736
|
+
}
|
|
17737
|
+
}
|
|
17738
|
+
}
|
|
17739
|
+
}
|
|
17740
|
+
return result;
|
|
17741
|
+
};
|
|
17742
|
+
EShapeEmbedded.prototype.toEedgePosition = function (lp, cp, sh, s) {
|
|
17743
|
+
if (0.00001 < Math.abs(s)) {
|
|
17744
|
+
return (lp + cp - sh) / s;
|
|
17745
|
+
}
|
|
17746
|
+
return 0;
|
|
17747
|
+
};
|
|
17748
|
+
EShapeEmbedded.prototype.toEedgeNormal = function (x, y) {
|
|
17749
|
+
var d = x * x + y * y;
|
|
17750
|
+
if (0.00001 < d) {
|
|
17751
|
+
var f = 1 / d;
|
|
17752
|
+
return {
|
|
17753
|
+
x: x * f,
|
|
17754
|
+
y: y * f
|
|
17755
|
+
};
|
|
17756
|
+
}
|
|
17757
|
+
return {
|
|
17758
|
+
x: 0,
|
|
17759
|
+
y: 1
|
|
17760
|
+
};
|
|
17761
|
+
};
|
|
17585
17762
|
EShapeEmbedded.prototype.isGroupSizeFittable = function () {
|
|
17586
17763
|
return false;
|
|
17587
17764
|
};
|
|
@@ -17727,29 +17904,6 @@
|
|
|
17727
17904
|
return EShapeEmbeddedDatum;
|
|
17728
17905
|
}());
|
|
17729
17906
|
|
|
17730
|
-
/*
|
|
17731
|
-
* Copyright (C) 2019 Toshiba Corporation
|
|
17732
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
17733
|
-
*/
|
|
17734
|
-
var EShapeAcceptorEdgeType = {
|
|
17735
|
-
TAIL: 1,
|
|
17736
|
-
HEAD: 2,
|
|
17737
|
-
ALL: 3
|
|
17738
|
-
};
|
|
17739
|
-
|
|
17740
|
-
/*
|
|
17741
|
-
* Copyright (C) 2019 Toshiba Corporation
|
|
17742
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
17743
|
-
*/
|
|
17744
|
-
var EShapeAcceptorEdgeSide = {
|
|
17745
|
-
NONE: 0,
|
|
17746
|
-
TOP: 1,
|
|
17747
|
-
RIGHT: 2,
|
|
17748
|
-
BOTTOM: 4,
|
|
17749
|
-
LEFT: 8,
|
|
17750
|
-
ALL: 15
|
|
17751
|
-
};
|
|
17752
|
-
|
|
17753
17907
|
/*
|
|
17754
17908
|
* Copyright (C) 2019 Toshiba Corporation
|
|
17755
17909
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -17847,6 +18001,39 @@
|
|
|
17847
18001
|
return EShapeAcceptorImpl;
|
|
17848
18002
|
}());
|
|
17849
18003
|
|
|
18004
|
+
var EShapeEmbeddedAcceptor = /** @class */ (function (_super) {
|
|
18005
|
+
__extends(EShapeEmbeddedAcceptor, _super);
|
|
18006
|
+
function EShapeEmbeddedAcceptor() {
|
|
18007
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
18008
|
+
}
|
|
18009
|
+
EShapeEmbeddedAcceptor.prototype.get = function (shape, id) {
|
|
18010
|
+
var edges = this.getEdges(shape);
|
|
18011
|
+
if (edges != null) {
|
|
18012
|
+
var edge = edges.get(id);
|
|
18013
|
+
if (edge != null) {
|
|
18014
|
+
return edge;
|
|
18015
|
+
}
|
|
18016
|
+
}
|
|
18017
|
+
return _super.prototype.get.call(this, shape, id);
|
|
18018
|
+
};
|
|
18019
|
+
EShapeEmbeddedAcceptor.prototype.each = function (shape, iteratee) {
|
|
18020
|
+
var edges = this.getEdges(shape);
|
|
18021
|
+
if (edges != null) {
|
|
18022
|
+
edges.forEach(function (edge, id) {
|
|
18023
|
+
iteratee(edge, id);
|
|
18024
|
+
});
|
|
18025
|
+
}
|
|
18026
|
+
return _super.prototype.each.call(this, shape, iteratee);
|
|
18027
|
+
};
|
|
18028
|
+
EShapeEmbeddedAcceptor.prototype.getEdges = function (shape) {
|
|
18029
|
+
if (shape instanceof EShapeEmbedded) {
|
|
18030
|
+
return shape.edges;
|
|
18031
|
+
}
|
|
18032
|
+
return null;
|
|
18033
|
+
};
|
|
18034
|
+
return EShapeEmbeddedAcceptor;
|
|
18035
|
+
}(EShapeAcceptorImpl));
|
|
18036
|
+
|
|
17850
18037
|
/*
|
|
17851
18038
|
* Copyright (C) 2019 Toshiba Corporation
|
|
17852
18039
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -17855,27 +18042,59 @@
|
|
|
17855
18042
|
function EShapeAcceptors() {
|
|
17856
18043
|
}
|
|
17857
18044
|
EShapeAcceptors.set = function (type, acceptor) {
|
|
17858
|
-
var
|
|
17859
|
-
if (
|
|
17860
|
-
|
|
17861
|
-
this.
|
|
18045
|
+
var acceptors = this._acceptors;
|
|
18046
|
+
if (acceptors == null) {
|
|
18047
|
+
acceptors = new Map();
|
|
18048
|
+
this._acceptors = acceptors;
|
|
17862
18049
|
}
|
|
17863
|
-
|
|
18050
|
+
acceptors.set(type, acceptor);
|
|
17864
18051
|
};
|
|
17865
18052
|
EShapeAcceptors.get = function (type) {
|
|
17866
18053
|
var _a;
|
|
17867
|
-
|
|
17868
|
-
|
|
17869
|
-
|
|
17870
|
-
|
|
17871
|
-
|
|
17872
|
-
|
|
17873
|
-
|
|
18054
|
+
var acceptors = this._acceptors;
|
|
18055
|
+
if (acceptors != null) {
|
|
18056
|
+
var acceptor = acceptors.get(type);
|
|
18057
|
+
if (acceptor != null) {
|
|
18058
|
+
return acceptor;
|
|
18059
|
+
}
|
|
18060
|
+
}
|
|
18061
|
+
var defaults = ((_a = this._defaults) !== null && _a !== void 0 ? _a : (this._defaults = new Map()));
|
|
18062
|
+
switch (type) {
|
|
18063
|
+
case EShapeType.EMBEDDED:
|
|
18064
|
+
var embedded = defaults.get(type);
|
|
18065
|
+
if (embedded == null) {
|
|
18066
|
+
embedded = this.newDefaultEmbedded();
|
|
18067
|
+
defaults.set(type, embedded);
|
|
18068
|
+
}
|
|
18069
|
+
return embedded;
|
|
18070
|
+
case EShapeType.EMBEDDED_ACCEPTOR_EDGE:
|
|
18071
|
+
var edge = defaults.get(type);
|
|
18072
|
+
if (edge == null) {
|
|
18073
|
+
edge = this.newDefaultEmbeddedAcceptorEdge();
|
|
18074
|
+
defaults.set(type, edge);
|
|
18075
|
+
}
|
|
18076
|
+
return edge;
|
|
18077
|
+
default:
|
|
18078
|
+
var other = defaults.get(null);
|
|
18079
|
+
if (other == null) {
|
|
18080
|
+
other = this.newDefaultOther();
|
|
18081
|
+
defaults.set(null, other);
|
|
18082
|
+
}
|
|
18083
|
+
return other;
|
|
17874
18084
|
}
|
|
17875
|
-
return result;
|
|
17876
18085
|
};
|
|
17877
|
-
EShapeAcceptors.
|
|
18086
|
+
EShapeAcceptors.newDefaultEmbedded = function () {
|
|
18087
|
+
return this.initDefault(new EShapeEmbeddedAcceptor());
|
|
18088
|
+
};
|
|
18089
|
+
EShapeAcceptors.newDefaultEmbeddedAcceptorEdge = function () {
|
|
17878
18090
|
var result = new EShapeAcceptorImpl();
|
|
18091
|
+
result.add("CENTER", EShapeAcceptorEdgeType.ALL, 0, 0, 0, 0);
|
|
18092
|
+
return result;
|
|
18093
|
+
};
|
|
18094
|
+
EShapeAcceptors.newDefaultOther = function () {
|
|
18095
|
+
return this.initDefault(new EShapeAcceptorImpl());
|
|
18096
|
+
};
|
|
18097
|
+
EShapeAcceptors.initDefault = function (result) {
|
|
17879
18098
|
var s = 1 / Math.sqrt(2);
|
|
17880
18099
|
result.add("TOP", EShapeAcceptorEdgeType.ALL, 0, -0.5, 0, -1);
|
|
17881
18100
|
result.add("LEFT", EShapeAcceptorEdgeType.ALL, -0.5, 0, -1, 0);
|
|
@@ -36425,28 +36644,6 @@
|
|
|
36425
36644
|
return null;
|
|
36426
36645
|
};
|
|
36427
36646
|
|
|
36428
|
-
/*
|
|
36429
|
-
* Copyright (C) 2019 Toshiba Corporation
|
|
36430
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
36431
|
-
*/
|
|
36432
|
-
var EShapeCircle = /** @class */ (function (_super) {
|
|
36433
|
-
__extends(EShapeCircle, _super);
|
|
36434
|
-
function EShapeCircle(type) {
|
|
36435
|
-
if (type === void 0) { type = EShapeType.CIRCLE; }
|
|
36436
|
-
return _super.call(this, type) || this;
|
|
36437
|
-
}
|
|
36438
|
-
EShapeCircle.prototype.clone = function () {
|
|
36439
|
-
return new EShapeCircle(this.type).copy(this);
|
|
36440
|
-
};
|
|
36441
|
-
EShapeCircle.prototype.containsAbs = function (x, y, ax, ay, sw, ss, sa) {
|
|
36442
|
-
if (_super.prototype.containsAbsBBox.call(this, x, y, ax, ay)) {
|
|
36443
|
-
return hitTestCircle(this, x, y, ax, ay, sw, ss);
|
|
36444
|
-
}
|
|
36445
|
-
return false;
|
|
36446
|
-
};
|
|
36447
|
-
return EShapeCircle;
|
|
36448
|
-
}(EShapePrimitive));
|
|
36449
|
-
|
|
36450
36647
|
/*
|
|
36451
36648
|
* Copyright (C) 2019 Toshiba Corporation
|
|
36452
36649
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -38712,15 +38909,53 @@
|
|
|
38712
38909
|
return null;
|
|
38713
38910
|
};
|
|
38714
38911
|
|
|
38912
|
+
/*
|
|
38913
|
+
* Copyright (C) 2019 Toshiba Corporation
|
|
38914
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
38915
|
+
*/
|
|
38916
|
+
var toSubtype = function (target) {
|
|
38917
|
+
var result = EShapeAcceptorEdgeType.ALL & target;
|
|
38918
|
+
if (result !== 0) {
|
|
38919
|
+
return result;
|
|
38920
|
+
}
|
|
38921
|
+
return EShapeAcceptorEdgeType.HEAD;
|
|
38922
|
+
};
|
|
38923
|
+
var toSide = function (target) {
|
|
38924
|
+
return (EShapeAcceptorEdgeSide.ALL & (target << 2));
|
|
38925
|
+
};
|
|
38926
|
+
var toVvisible = function (target) {
|
|
38927
|
+
return 0 < (0x1 & (target << 6));
|
|
38928
|
+
};
|
|
38929
|
+
var deserializeEmbeddedAcceptorEdge = function (item, manager, shape) {
|
|
38930
|
+
shape !== null && shape !== void 0 ? shape : (shape = new EShapeEmbeddedAcceptorEdge());
|
|
38931
|
+
var item15 = item[15];
|
|
38932
|
+
shape.subtype = toSubtype(item15);
|
|
38933
|
+
shape.side = toSide(item15);
|
|
38934
|
+
shape.vvisible = toVvisible(item15);
|
|
38935
|
+
var result = deserializeBase(item, manager, shape);
|
|
38936
|
+
if (shape.vvisible === false) {
|
|
38937
|
+
if (manager.mode === EShapeResourceManagerDeserializationMode.VIEWER) {
|
|
38938
|
+
shape.visible = false;
|
|
38939
|
+
}
|
|
38940
|
+
}
|
|
38941
|
+
return result;
|
|
38942
|
+
};
|
|
38943
|
+
|
|
38715
38944
|
/*
|
|
38716
38945
|
* Copyright (C) 2019 Toshiba Corporation
|
|
38717
38946
|
* SPDX-License-Identifier: Apache-2.0
|
|
38718
38947
|
*/
|
|
38719
38948
|
var loadShapeEmbedded = function () {
|
|
38949
|
+
// Embedded
|
|
38720
38950
|
EShapeUploadeds[EShapeType.EMBEDDED] = createGroupUploaded;
|
|
38721
38951
|
EShapeDeserializers[EShapeType.EMBEDDED] = deserializeEmbedded;
|
|
38722
38952
|
EShapeCapabilities.set(EShapeType.EMBEDDED, EShapeCapability.EMBEDDED);
|
|
38953
|
+
// Embedded layer
|
|
38723
38954
|
EShapeUploadeds[EShapeType.EMBEDDED_LAYER] = createRectanglePivotedUploaded;
|
|
38955
|
+
// Embedded acceptor edge
|
|
38956
|
+
EShapeUploadeds[EShapeType.EMBEDDED_ACCEPTOR_EDGE] = createCircleUploaded;
|
|
38957
|
+
EShapeDeserializers[EShapeType.EMBEDDED_ACCEPTOR_EDGE] = deserializeEmbeddedAcceptorEdge;
|
|
38958
|
+
EShapeCapabilities.set(EShapeType.EMBEDDED_ACCEPTOR_EDGE, EShapeCapability.EMBEDDED_ACCEPTOR_EDGE);
|
|
38724
38959
|
};
|
|
38725
38960
|
|
|
38726
38961
|
/*
|
|
@@ -75807,8 +76042,9 @@
|
|
|
75807
76042
|
deserializeConnectorElbow: deserializeConnectorElbow,
|
|
75808
76043
|
deserializeConnectorLine: deserializeConnectorLine,
|
|
75809
76044
|
onDeserializedConnectorLine: onDeserializedConnectorLine,
|
|
75810
|
-
|
|
76045
|
+
deserializeEmbeddedAcceptorEdge: deserializeEmbeddedAcceptorEdge,
|
|
75811
76046
|
deserializeEmbeddedLayer: deserializeEmbeddedLayer,
|
|
76047
|
+
deserializeEmbedded: deserializeEmbedded,
|
|
75812
76048
|
deserializeGradient: deserializeGradient,
|
|
75813
76049
|
deserializeGroupShadowed: deserializeGroupShadowed,
|
|
75814
76050
|
deserializeGroup: deserializeGroup,
|
|
@@ -75842,6 +76078,7 @@
|
|
|
75842
76078
|
EShapeConnectorElbowPointsFiller: EShapeConnectorElbowPointsFiller,
|
|
75843
76079
|
EShapeConnectorElbow: EShapeConnectorElbow,
|
|
75844
76080
|
EShapeConnectorLine: EShapeConnectorLine,
|
|
76081
|
+
EShapeEmbeddedAcceptorEdge: EShapeEmbeddedAcceptorEdge,
|
|
75845
76082
|
EShapeEmbeddedDatum: EShapeEmbeddedDatum,
|
|
75846
76083
|
EShapeEmbeddedLayerContainer: EShapeEmbeddedLayerContainer,
|
|
75847
76084
|
EShapeEmbeddedLayer: EShapeEmbeddedLayer,
|