@wcardinal/wcardinal-ui 0.397.0 → 0.399.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-base-state-set-impl.d.ts +5 -0
- package/dist/types/wcardinal/ui/d-base-state-set.d.ts +4 -0
- package/dist/types/wcardinal/ui/d-base-state.d.ts +1 -0
- package/dist/types/wcardinal/ui/d-base.d.ts +13 -1
- package/dist/types/wcardinal/ui/d-button-color.d.ts +0 -3
- package/dist/types/wcardinal/ui/d-image-base-theme-wrapper-other.d.ts +19 -0
- package/dist/types/wcardinal/ui/d-image-base-theme-wrapper-secondary.d.ts +3 -1
- package/dist/types/wcardinal/ui/d-image-base-theme-wrapper-tertiary.d.ts +3 -1
- package/dist/types/wcardinal/ui/d-image-base.d.ts +11 -26
- package/dist/types/wcardinal/ui/d-image-piece-align-impl.d.ts +23 -0
- package/dist/types/wcardinal/ui/d-image-piece-align.d.ts +14 -0
- package/dist/types/wcardinal/ui/d-image-piece-container-impl.d.ts +24 -0
- package/dist/types/wcardinal/ui/d-image-piece-container.d.ts +12 -0
- package/dist/types/wcardinal/ui/d-image-piece-impl.d.ts +60 -0
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part-bottom.d.ts +3 -0
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part-center.d.ts +2 -1
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part-left.d.ts +3 -0
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part-middle.d.ts +2 -1
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part-right.d.ts +3 -0
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part-top.d.ts +3 -0
- package/dist/types/wcardinal/ui/d-image-piece-layouter-part.d.ts +4 -2
- package/dist/types/wcardinal/ui/d-image-piece-margin-impl.d.ts +17 -0
- package/dist/types/wcardinal/ui/d-image-piece-margin.d.ts +9 -0
- package/dist/types/wcardinal/ui/d-image-piece-tint-impl.d.ts +23 -0
- package/dist/types/wcardinal/ui/d-image-piece-tint.d.ts +13 -0
- package/dist/types/wcardinal/ui/d-image-piece.d.ts +14 -77
- package/dist/types/wcardinal/ui/d-indicator-processing.d.ts +69 -0
- package/dist/types/wcardinal/ui/index.d.ts +11 -0
- package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-en-us-dialog-processing.d.ts +2 -0
- package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-en-us-indicator-processing.d.ts +5 -0
- package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-image-base.d.ts +3 -0
- package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-indicator-processing.d.ts +13 -0
- package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-ja-jp-dialog-processing.d.ts +2 -0
- package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-ja-jp-indicator-processing.d.ts +5 -0
- package/dist/types/wcardinal/ui/theme/dark/index-en-us.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/dark/index-ja-jp.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/dark/index-zz-zz.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/dark/load/index-en-us.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/dark/load/index-ja-jp.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/dark/load/load-theme-dark-en-us-indicator-processing.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/dark/load/load-theme-dark-ja-jp-indicator-processing.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/d-theme-white-en-us-dialog-processing.d.ts +2 -0
- package/dist/types/wcardinal/ui/theme/white/d-theme-white-en-us-indicator-processing.d.ts +5 -0
- package/dist/types/wcardinal/ui/theme/white/d-theme-white-image-base.d.ts +3 -0
- package/dist/types/wcardinal/ui/theme/white/d-theme-white-indicator-processing.d.ts +13 -0
- package/dist/types/wcardinal/ui/theme/white/d-theme-white-ja-jp-dialog-processing.d.ts +2 -0
- package/dist/types/wcardinal/ui/theme/white/d-theme-white-ja-jp-indicator-processing.d.ts +5 -0
- package/dist/types/wcardinal/ui/theme/white/index-en-us.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/index-ja-jp.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/index-zz-zz.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/load/index-en-us.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/load/index-ja-jp.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/load/load-theme-white-en-us-indicator-processing.d.ts +1 -0
- package/dist/types/wcardinal/ui/theme/white/load/load-theme-white-ja-jp-indicator-processing.d.ts +1 -0
- package/dist/wcardinal/ui/d-base-state-set-impl.js +31 -0
- package/dist/wcardinal/ui/d-base-state-set-impl.js.map +1 -1
- package/dist/wcardinal/ui/d-base-state-set.js.map +1 -1
- package/dist/wcardinal/ui/d-base-state.js +1 -0
- package/dist/wcardinal/ui/d-base-state.js.map +1 -1
- package/dist/wcardinal/ui/d-base.js +63 -7
- package/dist/wcardinal/ui/d-base.js.map +1 -1
- package/dist/wcardinal/ui/d-button-color.js +6 -29
- package/dist/wcardinal/ui/d-button-color.js.map +1 -1
- package/dist/wcardinal/ui/d-dialog-processing.js +3 -2
- package/dist/wcardinal/ui/d-dialog-processing.js.map +1 -1
- package/dist/wcardinal/ui/d-image-base-theme-wrapper-other.js +35 -0
- package/dist/wcardinal/ui/d-image-base-theme-wrapper-other.js.map +1 -0
- package/dist/wcardinal/ui/d-image-base-theme-wrapper-secondary.js +5 -1
- package/dist/wcardinal/ui/d-image-base-theme-wrapper-secondary.js.map +1 -1
- package/dist/wcardinal/ui/d-image-base-theme-wrapper-tertiary.js +5 -1
- package/dist/wcardinal/ui/d-image-base-theme-wrapper-tertiary.js.map +1 -1
- package/dist/wcardinal/ui/d-image-base.js +22 -51
- package/dist/wcardinal/ui/d-image-base.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-align-impl.js +89 -0
- package/dist/wcardinal/ui/d-image-piece-align-impl.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-align.js +2 -0
- package/dist/wcardinal/ui/d-image-piece-align.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-container-impl.js +108 -0
- package/dist/wcardinal/ui/d-image-piece-container-impl.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-container.js +2 -0
- package/dist/wcardinal/ui/d-image-piece-container.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-impl.js +235 -0
- package/dist/wcardinal/ui/d-image-piece-impl.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-layouter-part-bottom.js +15 -4
- package/dist/wcardinal/ui/d-image-piece-layouter-part-bottom.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part-center.js +6 -3
- package/dist/wcardinal/ui/d-image-piece-layouter-part-center.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part-container.js +13 -17
- package/dist/wcardinal/ui/d-image-piece-layouter-part-container.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part-left.js +15 -4
- package/dist/wcardinal/ui/d-image-piece-layouter-part-left.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part-middle.js +8 -5
- package/dist/wcardinal/ui/d-image-piece-layouter-part-middle.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part-right.js +15 -4
- package/dist/wcardinal/ui/d-image-piece-layouter-part-right.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part-top.js +15 -4
- package/dist/wcardinal/ui/d-image-piece-layouter-part-top.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter-part.js +1 -6
- package/dist/wcardinal/ui/d-image-piece-layouter-part.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-layouter.js +2 -2
- package/dist/wcardinal/ui/d-image-piece-layouter.js.map +1 -1
- package/dist/wcardinal/ui/d-image-piece-margin-impl.js +55 -0
- package/dist/wcardinal/ui/d-image-piece-margin-impl.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-margin.js +2 -0
- package/dist/wcardinal/ui/d-image-piece-margin.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-tint-impl.js +90 -0
- package/dist/wcardinal/ui/d-image-piece-tint-impl.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece-tint.js +2 -0
- package/dist/wcardinal/ui/d-image-piece-tint.js.map +1 -0
- package/dist/wcardinal/ui/d-image-piece.js +1 -287
- package/dist/wcardinal/ui/d-image-piece.js.map +1 -1
- package/dist/wcardinal/ui/d-indicator-processing.js +216 -0
- package/dist/wcardinal/ui/d-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/d-table-header-cell.js +10 -5
- package/dist/wcardinal/ui/d-table-header-cell.js.map +1 -1
- package/dist/wcardinal/ui/d-text-base.js +9 -1
- package/dist/wcardinal/ui/d-text-base.js.map +1 -1
- package/dist/wcardinal/ui/index.js +11 -0
- package/dist/wcardinal/ui/index.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-en-us-dialog-processing.js +2 -2
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-en-us-dialog-processing.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-en-us-indicator-processing.js +19 -0
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-en-us-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-image-base.js +9 -0
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-image-base.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-indicator-processing.js +68 -0
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-ja-jp-dialog-processing.js +2 -2
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-ja-jp-dialog-processing.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-ja-jp-indicator-processing.js +19 -0
- package/dist/wcardinal/ui/theme/dark/d-theme-dark-ja-jp-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/dark/index-en-us.js +1 -0
- package/dist/wcardinal/ui/theme/dark/index-en-us.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/index-ja-jp.js +1 -0
- package/dist/wcardinal/ui/theme/dark/index-ja-jp.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/index-zz-zz.js +1 -0
- package/dist/wcardinal/ui/theme/dark/index-zz-zz.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/load/index-en-us.js +1 -0
- package/dist/wcardinal/ui/theme/dark/load/index-en-us.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/load/index-ja-jp.js +1 -0
- package/dist/wcardinal/ui/theme/dark/load/index-ja-jp.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-en-us-all.js +2 -0
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-en-us-all.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-en-us-indicator-processing.js +10 -0
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-en-us-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-ja-jp-all.js +2 -0
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-ja-jp-all.js.map +1 -1
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-ja-jp-indicator-processing.js +10 -0
- package/dist/wcardinal/ui/theme/dark/load/load-theme-dark-ja-jp-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-en-us-dialog-processing.js +2 -2
- package/dist/wcardinal/ui/theme/white/d-theme-white-en-us-dialog-processing.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/d-theme-white-en-us-indicator-processing.js +19 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-en-us-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-image-base.js +9 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-image-base.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/d-theme-white-indicator-processing.js +68 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-ja-jp-dialog-processing.js +2 -2
- package/dist/wcardinal/ui/theme/white/d-theme-white-ja-jp-dialog-processing.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/d-theme-white-ja-jp-indicator-processing.js +19 -0
- package/dist/wcardinal/ui/theme/white/d-theme-white-ja-jp-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/white/index-en-us.js +1 -0
- package/dist/wcardinal/ui/theme/white/index-en-us.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/index-ja-jp.js +1 -0
- package/dist/wcardinal/ui/theme/white/index-ja-jp.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/index-zz-zz.js +1 -0
- package/dist/wcardinal/ui/theme/white/index-zz-zz.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/load/index-en-us.js +1 -0
- package/dist/wcardinal/ui/theme/white/load/index-en-us.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/load/index-ja-jp.js +1 -0
- package/dist/wcardinal/ui/theme/white/load/index-ja-jp.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-en-us-all.js +2 -0
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-en-us-all.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-en-us-indicator-processing.js +10 -0
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-en-us-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-ja-jp-all.js +2 -0
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-ja-jp-all.js.map +1 -1
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-ja-jp-indicator-processing.js +10 -0
- package/dist/wcardinal/ui/theme/white/load/load-theme-white-ja-jp-indicator-processing.js.map +1 -0
- package/dist/wcardinal/ui/util/util-svg-atlas-builder.js +1 -1
- package/dist/wcardinal/ui/util/util-svg-atlas-builder.js.map +1 -1
- package/dist/wcardinal-ui-theme-dark-en-us.js +105 -3
- package/dist/wcardinal-ui-theme-dark-en-us.min.js +2 -2
- package/dist/wcardinal-ui-theme-dark-en-us.min.js.map +1 -1
- package/dist/wcardinal-ui-theme-dark-ja-jp.js +105 -3
- package/dist/wcardinal-ui-theme-dark-ja-jp.min.js +2 -2
- package/dist/wcardinal-ui-theme-dark-ja-jp.min.js.map +1 -1
- package/dist/wcardinal-ui-theme-dark.js +105 -3
- package/dist/wcardinal-ui-theme-dark.min.js +2 -2
- package/dist/wcardinal-ui-theme-white-en-us.js +105 -3
- package/dist/wcardinal-ui-theme-white-en-us.min.js +2 -2
- package/dist/wcardinal-ui-theme-white-en-us.min.js.map +1 -1
- package/dist/wcardinal-ui-theme-white-ja-jp.js +105 -3
- package/dist/wcardinal-ui-theme-white-ja-jp.min.js +2 -2
- package/dist/wcardinal-ui-theme-white-ja-jp.min.js.map +1 -1
- package/dist/wcardinal-ui-theme-white.js +105 -3
- package/dist/wcardinal-ui-theme-white.min.js +2 -2
- package/dist/wcardinal-ui.cjs.js +1391 -502
- package/dist/wcardinal-ui.js +1125 -494
- 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.399.0
|
|
3
3
|
Copyright (C) 2019 Toshiba Corporation
|
|
4
4
|
SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
|
|
@@ -2671,6 +2671,7 @@
|
|
|
2671
2671
|
GESTURING: "GESTURING",
|
|
2672
2672
|
PRESSED: "PRESSED",
|
|
2673
2673
|
INVALID: "INVALID",
|
|
2674
|
+
PROCESSING: "PROCESSING",
|
|
2674
2675
|
SUCCEEDED: "SUCCEEDED",
|
|
2675
2676
|
FAILED: "FAILED",
|
|
2676
2677
|
WARNED: "WARNED",
|
|
@@ -3735,6 +3736,37 @@
|
|
|
3735
3736
|
enumerable: false,
|
|
3736
3737
|
configurable: true
|
|
3737
3738
|
});
|
|
3739
|
+
Object.defineProperty(DBaseStateSetImpl.prototype, "isProcessing", {
|
|
3740
|
+
get: function () {
|
|
3741
|
+
return this.is(DBaseState.PROCESSING);
|
|
3742
|
+
},
|
|
3743
|
+
set: function (processing) {
|
|
3744
|
+
this.set(DBaseState.PROCESSING, processing);
|
|
3745
|
+
},
|
|
3746
|
+
enumerable: false,
|
|
3747
|
+
configurable: true
|
|
3748
|
+
});
|
|
3749
|
+
Object.defineProperty(DBaseStateSetImpl.prototype, "inProcessing", {
|
|
3750
|
+
get: function () {
|
|
3751
|
+
return this.in(DBaseState.PROCESSING);
|
|
3752
|
+
},
|
|
3753
|
+
enumerable: false,
|
|
3754
|
+
configurable: true
|
|
3755
|
+
});
|
|
3756
|
+
Object.defineProperty(DBaseStateSetImpl.prototype, "onProcessing", {
|
|
3757
|
+
get: function () {
|
|
3758
|
+
return this.on(DBaseState.PROCESSING);
|
|
3759
|
+
},
|
|
3760
|
+
enumerable: false,
|
|
3761
|
+
configurable: true
|
|
3762
|
+
});
|
|
3763
|
+
Object.defineProperty(DBaseStateSetImpl.prototype, "underProcessing", {
|
|
3764
|
+
get: function () {
|
|
3765
|
+
return this.under(DBaseState.PROCESSING);
|
|
3766
|
+
},
|
|
3767
|
+
enumerable: false,
|
|
3768
|
+
configurable: true
|
|
3769
|
+
});
|
|
3738
3770
|
Object.defineProperty(DBaseStateSetImpl.prototype, "isSucceeded", {
|
|
3739
3771
|
get: function () {
|
|
3740
3772
|
return this.is(DBaseState.SUCCEEDED);
|
|
@@ -14822,11 +14854,35 @@
|
|
|
14822
14854
|
for (var i = 0, imax = children.length; i < imax; ++i) {
|
|
14823
14855
|
var child = children[i];
|
|
14824
14856
|
if (child.visible) {
|
|
14825
|
-
|
|
14826
|
-
|
|
14827
|
-
|
|
14828
|
-
|
|
14829
|
-
|
|
14857
|
+
var rw = this.hasRefitableWidth(child);
|
|
14858
|
+
var rh = this.hasRefitableHeight(child);
|
|
14859
|
+
if (rw || rh) {
|
|
14860
|
+
if (child instanceof DBase) {
|
|
14861
|
+
if (rw) {
|
|
14862
|
+
width = Math.max(width, child.x + child.width);
|
|
14863
|
+
}
|
|
14864
|
+
if (rh) {
|
|
14865
|
+
height = Math.max(height, child.y + child.height);
|
|
14866
|
+
}
|
|
14867
|
+
}
|
|
14868
|
+
else if (child instanceof pixi_js.Container) {
|
|
14869
|
+
var bound = child.getLocalBounds(undefined, true);
|
|
14870
|
+
if (rw) {
|
|
14871
|
+
width = Math.max(width, child.x + bound.x + bound.width);
|
|
14872
|
+
}
|
|
14873
|
+
if (rh) {
|
|
14874
|
+
height = Math.max(height, child.y + bound.y + bound.height);
|
|
14875
|
+
}
|
|
14876
|
+
}
|
|
14877
|
+
else {
|
|
14878
|
+
var bound = child.getLocalBounds();
|
|
14879
|
+
if (rw) {
|
|
14880
|
+
width = Math.max(width, child.x + bound.x + bound.width);
|
|
14881
|
+
}
|
|
14882
|
+
if (rh) {
|
|
14883
|
+
height = Math.max(height, child.y + bound.y + bound.height);
|
|
14884
|
+
}
|
|
14885
|
+
}
|
|
14830
14886
|
}
|
|
14831
14887
|
}
|
|
14832
14888
|
}
|
|
@@ -14839,7 +14895,17 @@
|
|
|
14839
14895
|
for (var i = 0, imax = children.length; i < imax; ++i) {
|
|
14840
14896
|
var child = children[i];
|
|
14841
14897
|
if (child.visible && this.hasRefitableWidth(child)) {
|
|
14842
|
-
|
|
14898
|
+
if (child instanceof DBase) {
|
|
14899
|
+
width = Math.max(width, child.x + child.width);
|
|
14900
|
+
}
|
|
14901
|
+
else if (child instanceof pixi_js.Container) {
|
|
14902
|
+
var bound = child.getLocalBounds(undefined, true);
|
|
14903
|
+
width = Math.max(width, child.x + bound.x + bound.width);
|
|
14904
|
+
}
|
|
14905
|
+
else {
|
|
14906
|
+
var bound = child.getLocalBounds();
|
|
14907
|
+
width = Math.max(width, child.x + bound.x + bound.width);
|
|
14908
|
+
}
|
|
14843
14909
|
}
|
|
14844
14910
|
}
|
|
14845
14911
|
this.resize(width + this.padding.getRight(), undefined);
|
|
@@ -14850,7 +14916,17 @@
|
|
|
14850
14916
|
for (var i = 0, imax = children.length; i < imax; ++i) {
|
|
14851
14917
|
var child = children[i];
|
|
14852
14918
|
if (child.visible && this.hasRefitableHeight(child)) {
|
|
14853
|
-
|
|
14919
|
+
if (child instanceof DBase) {
|
|
14920
|
+
height = Math.max(height, child.y + child.height);
|
|
14921
|
+
}
|
|
14922
|
+
else if (child instanceof pixi_js.Container) {
|
|
14923
|
+
var bound = child.getLocalBounds(undefined, true);
|
|
14924
|
+
height = Math.max(height, child.y + bound.y + bound.height);
|
|
14925
|
+
}
|
|
14926
|
+
else {
|
|
14927
|
+
var bound = child.getLocalBounds();
|
|
14928
|
+
height = Math.max(height, child.y + bound.y + bound.height);
|
|
14929
|
+
}
|
|
14854
14930
|
}
|
|
14855
14931
|
}
|
|
14856
14932
|
this.resize(undefined, height + this.padding.getBottom());
|
|
@@ -14859,9 +14935,21 @@
|
|
|
14859
14935
|
DBase.prototype.isRefitable = function (target) {
|
|
14860
14936
|
return target instanceof DBase;
|
|
14861
14937
|
};
|
|
14938
|
+
/**
|
|
14939
|
+
* Returns true if the given target has a height that doesn't depend on its parent height.
|
|
14940
|
+
*
|
|
14941
|
+
* @param target a target
|
|
14942
|
+
* @returns true if the given target has a height that doesn't depend on its parent height.
|
|
14943
|
+
*/
|
|
14862
14944
|
DBase.prototype.hasRefitableHeight = function (target) {
|
|
14863
14945
|
return (this.isRefitable(target) && !(target instanceof DBase && isFunction(target.getHeight())));
|
|
14864
14946
|
};
|
|
14947
|
+
/**
|
|
14948
|
+
* Returns true if the given target has a width that doesn't depend on its parent width.
|
|
14949
|
+
*
|
|
14950
|
+
* @param target a target
|
|
14951
|
+
* @returns true if the given target has a width that doesn't depend on its parent width.
|
|
14952
|
+
*/
|
|
14865
14953
|
DBase.prototype.hasRefitableWidth = function (target) {
|
|
14866
14954
|
return (this.isRefitable(target) && !(target instanceof DBase && isFunction(target.getWidth())));
|
|
14867
14955
|
};
|
|
@@ -27569,67 +27657,15 @@
|
|
|
27569
27657
|
DOUBLE_CLICKED: 1
|
|
27570
27658
|
};
|
|
27571
27659
|
|
|
27572
|
-
|
|
27573
|
-
|
|
27574
|
-
|
|
27575
|
-
|
|
27576
|
-
|
|
27577
|
-
|
|
27578
|
-
|
|
27579
|
-
|
|
27580
|
-
|
|
27581
|
-
};
|
|
27582
|
-
DImageBaseThemeWrapperSecondary.prototype.getImageAlignWith = function () {
|
|
27583
|
-
return this._theme.getSecondaryImageAlignWith();
|
|
27584
|
-
};
|
|
27585
|
-
DImageBaseThemeWrapperSecondary.prototype.getImageMarginHorizontal = function () {
|
|
27586
|
-
return this._theme.getSecondaryImageMarginHorizontal();
|
|
27587
|
-
};
|
|
27588
|
-
DImageBaseThemeWrapperSecondary.prototype.getImageMarginVertial = function () {
|
|
27589
|
-
return this._theme.getSecondaryImageMarginVertial();
|
|
27590
|
-
};
|
|
27591
|
-
DImageBaseThemeWrapperSecondary.prototype.getImageTintColor = function (state) {
|
|
27592
|
-
return this._theme.getSecondaryImageTintColor(state);
|
|
27593
|
-
};
|
|
27594
|
-
DImageBaseThemeWrapperSecondary.prototype.getImageTintAlpha = function (state) {
|
|
27595
|
-
return this._theme.getSecondaryImageTintAlpha(state);
|
|
27596
|
-
};
|
|
27597
|
-
DImageBaseThemeWrapperSecondary.prototype.getImageSource = function (state) {
|
|
27598
|
-
return this._theme.getSecondaryImageSource(state);
|
|
27599
|
-
};
|
|
27600
|
-
return DImageBaseThemeWrapperSecondary;
|
|
27601
|
-
}());
|
|
27602
|
-
|
|
27603
|
-
var DImageBaseThemeWrapperTertiary = /** @class */ (function () {
|
|
27604
|
-
function DImageBaseThemeWrapperTertiary(theme) {
|
|
27605
|
-
this._theme = theme;
|
|
27606
|
-
}
|
|
27607
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageAlignHorizontal = function () {
|
|
27608
|
-
return this._theme.getTertiaryImageAlignHorizontal();
|
|
27609
|
-
};
|
|
27610
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageAlignVertical = function () {
|
|
27611
|
-
return this._theme.getTertiaryImageAlignVertical();
|
|
27612
|
-
};
|
|
27613
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageAlignWith = function () {
|
|
27614
|
-
return this._theme.getTertiaryImageAlignWith();
|
|
27615
|
-
};
|
|
27616
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageMarginHorizontal = function () {
|
|
27617
|
-
return this._theme.getTertiaryImageMarginHorizontal();
|
|
27618
|
-
};
|
|
27619
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageMarginVertial = function () {
|
|
27620
|
-
return this._theme.getTertiaryImageMarginVertial();
|
|
27621
|
-
};
|
|
27622
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageTintColor = function (state) {
|
|
27623
|
-
return this._theme.getTertiaryImageTintColor(state);
|
|
27624
|
-
};
|
|
27625
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageTintAlpha = function (state) {
|
|
27626
|
-
return this._theme.getTertiaryImageTintAlpha(state);
|
|
27627
|
-
};
|
|
27628
|
-
DImageBaseThemeWrapperTertiary.prototype.getImageSource = function (state) {
|
|
27629
|
-
return this._theme.getTertiaryImageSource(state);
|
|
27630
|
-
};
|
|
27631
|
-
return DImageBaseThemeWrapperTertiary;
|
|
27632
|
-
}());
|
|
27660
|
+
/*
|
|
27661
|
+
* Copyright (C) 2019 Toshiba Corporation
|
|
27662
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
27663
|
+
*/
|
|
27664
|
+
var DAlignWith = {
|
|
27665
|
+
TEXT: 0,
|
|
27666
|
+
PADDING: 1,
|
|
27667
|
+
BORDER: 2
|
|
27668
|
+
};
|
|
27633
27669
|
|
|
27634
27670
|
/*
|
|
27635
27671
|
* Copyright (C) 2019 Toshiba Corporation
|
|
@@ -27651,299 +27687,10 @@
|
|
|
27651
27687
|
BOTTOM: 2
|
|
27652
27688
|
};
|
|
27653
27689
|
|
|
27654
|
-
/*
|
|
27655
|
-
* Copyright (C) 2019 Toshiba Corporation
|
|
27656
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
27657
|
-
*/
|
|
27658
|
-
var DAlignWith = {
|
|
27659
|
-
TEXT: 0,
|
|
27660
|
-
PADDING: 1,
|
|
27661
|
-
BORDER: 2
|
|
27662
|
-
};
|
|
27663
|
-
|
|
27664
|
-
var toImageAlign = function (theme, options) {
|
|
27665
|
-
var _a, _b, _c;
|
|
27666
|
-
var align = options === null || options === void 0 ? void 0 : options.align;
|
|
27667
|
-
return {
|
|
27668
|
-
with: toEnum((_a = align === null || align === void 0 ? void 0 : align.with) !== null && _a !== void 0 ? _a : theme.getImageAlignWith(), DAlignWith),
|
|
27669
|
-
vertical: toEnum((_b = align === null || align === void 0 ? void 0 : align.vertical) !== null && _b !== void 0 ? _b : theme.getImageAlignVertical(), DAlignVertical),
|
|
27670
|
-
horizontal: toEnum((_c = align === null || align === void 0 ? void 0 : align.horizontal) !== null && _c !== void 0 ? _c : theme.getImageAlignHorizontal(), DAlignHorizontal)
|
|
27671
|
-
};
|
|
27672
|
-
};
|
|
27673
|
-
var toImageMargin = function (theme, options) {
|
|
27674
|
-
var _a, _b;
|
|
27675
|
-
var margin = options === null || options === void 0 ? void 0 : options.margin;
|
|
27676
|
-
return {
|
|
27677
|
-
vertical: (_a = margin === null || margin === void 0 ? void 0 : margin.vertical) !== null && _a !== void 0 ? _a : theme.getImageMarginVertial(),
|
|
27678
|
-
horizontal: (_b = margin === null || margin === void 0 ? void 0 : margin.horizontal) !== null && _b !== void 0 ? _b : theme.getImageMarginHorizontal()
|
|
27679
|
-
};
|
|
27680
|
-
};
|
|
27681
|
-
var DImagePiece = /** @class */ (function () {
|
|
27682
|
-
function DImagePiece(parent, theme, textAlign, options) {
|
|
27683
|
-
var _this = this;
|
|
27684
|
-
this._parent = parent;
|
|
27685
|
-
this._theme = theme;
|
|
27686
|
-
this._textAlign = textAlign;
|
|
27687
|
-
this._image = null;
|
|
27688
|
-
this._align = toImageAlign(theme, options);
|
|
27689
|
-
this._margin = toImageMargin(theme, options);
|
|
27690
|
-
this._tint = options === null || options === void 0 ? void 0 : options.tint;
|
|
27691
|
-
this._bound = new pixi_js.Rectangle();
|
|
27692
|
-
this._source = options === null || options === void 0 ? void 0 : options.source;
|
|
27693
|
-
this._computed = null;
|
|
27694
|
-
this._onUpdateBound = function () {
|
|
27695
|
-
_this.onUpdate();
|
|
27696
|
-
};
|
|
27697
|
-
}
|
|
27698
|
-
Object.defineProperty(DImagePiece.prototype, "image", {
|
|
27699
|
-
get: function () {
|
|
27700
|
-
return this._image;
|
|
27701
|
-
},
|
|
27702
|
-
enumerable: false,
|
|
27703
|
-
configurable: true
|
|
27704
|
-
});
|
|
27705
|
-
Object.defineProperty(DImagePiece.prototype, "align", {
|
|
27706
|
-
get: function () {
|
|
27707
|
-
return this._align;
|
|
27708
|
-
},
|
|
27709
|
-
enumerable: false,
|
|
27710
|
-
configurable: true
|
|
27711
|
-
});
|
|
27712
|
-
Object.defineProperty(DImagePiece.prototype, "margin", {
|
|
27713
|
-
get: function () {
|
|
27714
|
-
return this._margin;
|
|
27715
|
-
},
|
|
27716
|
-
enumerable: false,
|
|
27717
|
-
configurable: true
|
|
27718
|
-
});
|
|
27719
|
-
Object.defineProperty(DImagePiece.prototype, "bound", {
|
|
27720
|
-
get: function () {
|
|
27721
|
-
return this._bound;
|
|
27722
|
-
},
|
|
27723
|
-
enumerable: false,
|
|
27724
|
-
configurable: true
|
|
27725
|
-
});
|
|
27726
|
-
Object.defineProperty(DImagePiece.prototype, "source", {
|
|
27727
|
-
get: function () {
|
|
27728
|
-
return this._source;
|
|
27729
|
-
},
|
|
27730
|
-
set: function (source) {
|
|
27731
|
-
if (this._source !== source) {
|
|
27732
|
-
this._source = source;
|
|
27733
|
-
this.onUpdate();
|
|
27734
|
-
}
|
|
27735
|
-
},
|
|
27736
|
-
enumerable: false,
|
|
27737
|
-
configurable: true
|
|
27738
|
-
});
|
|
27739
|
-
DImagePiece.prototype.computeSource = function () {
|
|
27740
|
-
var source = this._source;
|
|
27741
|
-
if (source !== undefined) {
|
|
27742
|
-
if (isFunction(source)) {
|
|
27743
|
-
var result = source(this._parent.state);
|
|
27744
|
-
if (result !== undefined) {
|
|
27745
|
-
return result;
|
|
27746
|
-
}
|
|
27747
|
-
}
|
|
27748
|
-
else {
|
|
27749
|
-
return source;
|
|
27750
|
-
}
|
|
27751
|
-
}
|
|
27752
|
-
return this._theme.getImageSource(this._parent.state);
|
|
27753
|
-
};
|
|
27754
|
-
DImagePiece.prototype.onStateChange = function (newState, oldState) {
|
|
27755
|
-
this.updateTint();
|
|
27756
|
-
};
|
|
27757
|
-
DImagePiece.prototype.updateBound = function () {
|
|
27758
|
-
var bound = this._bound;
|
|
27759
|
-
var image = this._image;
|
|
27760
|
-
if (image != null) {
|
|
27761
|
-
image.updateTransform();
|
|
27762
|
-
image.getLocalBounds(bound);
|
|
27763
|
-
var bl = bound.left;
|
|
27764
|
-
var bt = bound.top;
|
|
27765
|
-
var br = bound.right;
|
|
27766
|
-
var bb = bound.bottom;
|
|
27767
|
-
var localTransform = image.localTransform;
|
|
27768
|
-
var a = localTransform.a;
|
|
27769
|
-
var b = localTransform.b;
|
|
27770
|
-
var c = localTransform.c;
|
|
27771
|
-
var d = localTransform.d;
|
|
27772
|
-
var x0 = a * bl + c * bt;
|
|
27773
|
-
var y0 = b * bl + d * bt;
|
|
27774
|
-
var x1 = a * br + c * bt;
|
|
27775
|
-
var y1 = b * br + d * bt;
|
|
27776
|
-
var x2 = a * br + c * bb;
|
|
27777
|
-
var y2 = b * br + d * bb;
|
|
27778
|
-
var x3 = a * bl + c * bb;
|
|
27779
|
-
var y3 = b * bl + d * bb;
|
|
27780
|
-
var xmin = Math.min(x0, x1, x2, x3);
|
|
27781
|
-
var xmax = Math.max(x0, x1, x2, x3);
|
|
27782
|
-
var ymin = Math.min(y0, y1, y2, y3);
|
|
27783
|
-
var ymax = Math.max(y0, y1, y2, y3);
|
|
27784
|
-
bound.x = xmin + localTransform.tx;
|
|
27785
|
-
bound.y = ymin + localTransform.ty;
|
|
27786
|
-
bound.width = xmax - xmin;
|
|
27787
|
-
bound.height = ymax - ymin;
|
|
27788
|
-
}
|
|
27789
|
-
else {
|
|
27790
|
-
bound.x = 0;
|
|
27791
|
-
bound.y = 0;
|
|
27792
|
-
bound.width = 0;
|
|
27793
|
-
bound.height = 0;
|
|
27794
|
-
}
|
|
27795
|
-
};
|
|
27796
|
-
DImagePiece.prototype.isTintAware = function (target) {
|
|
27797
|
-
return target != null && "tint" in target;
|
|
27798
|
-
};
|
|
27799
|
-
DImagePiece.prototype.toTintColor = function (theme, state) {
|
|
27800
|
-
var tint = this._tint;
|
|
27801
|
-
if (tint) {
|
|
27802
|
-
var color = tint.color;
|
|
27803
|
-
if (color !== undefined) {
|
|
27804
|
-
if (isFunction(color)) {
|
|
27805
|
-
var result = color(state);
|
|
27806
|
-
if (result !== undefined) {
|
|
27807
|
-
return result;
|
|
27808
|
-
}
|
|
27809
|
-
}
|
|
27810
|
-
else {
|
|
27811
|
-
return color;
|
|
27812
|
-
}
|
|
27813
|
-
}
|
|
27814
|
-
}
|
|
27815
|
-
return theme.getImageTintColor(state);
|
|
27816
|
-
};
|
|
27817
|
-
DImagePiece.prototype.toTintAlpha = function (theme, state) {
|
|
27818
|
-
var tint = this._tint;
|
|
27819
|
-
if (tint) {
|
|
27820
|
-
var alpha = tint.alpha;
|
|
27821
|
-
if (alpha !== undefined) {
|
|
27822
|
-
if (isFunction(alpha)) {
|
|
27823
|
-
var result = alpha(state);
|
|
27824
|
-
if (result !== undefined) {
|
|
27825
|
-
return result;
|
|
27826
|
-
}
|
|
27827
|
-
}
|
|
27828
|
-
else {
|
|
27829
|
-
return alpha;
|
|
27830
|
-
}
|
|
27831
|
-
}
|
|
27832
|
-
}
|
|
27833
|
-
return theme.getImageTintAlpha(state);
|
|
27834
|
-
};
|
|
27835
|
-
/**
|
|
27836
|
-
* Updates the tint.
|
|
27837
|
-
*
|
|
27838
|
-
* @returns True if the tint is changed.
|
|
27839
|
-
*/
|
|
27840
|
-
DImagePiece.prototype.updateTint = function () {
|
|
27841
|
-
var image = this._image;
|
|
27842
|
-
if (image) {
|
|
27843
|
-
if (this.isTintAware(image)) {
|
|
27844
|
-
var theme = this._theme;
|
|
27845
|
-
var state = this._parent.state;
|
|
27846
|
-
var color = this.toTintColor(theme, state);
|
|
27847
|
-
if (color != null) {
|
|
27848
|
-
var result = false;
|
|
27849
|
-
if (image.tint !== color) {
|
|
27850
|
-
image.tint = color;
|
|
27851
|
-
result = true;
|
|
27852
|
-
}
|
|
27853
|
-
var alpha = this.toTintAlpha(theme, state);
|
|
27854
|
-
if (image.alpha !== alpha) {
|
|
27855
|
-
image.alpha = alpha;
|
|
27856
|
-
result = true;
|
|
27857
|
-
}
|
|
27858
|
-
return result;
|
|
27859
|
-
}
|
|
27860
|
-
}
|
|
27861
|
-
}
|
|
27862
|
-
return false;
|
|
27863
|
-
};
|
|
27864
|
-
/**
|
|
27865
|
-
* Updates the computed source.
|
|
27866
|
-
*
|
|
27867
|
-
* @returns True if the computed source is changed
|
|
27868
|
-
*/
|
|
27869
|
-
DImagePiece.prototype.updateSource = function () {
|
|
27870
|
-
var newComputed = this.computeSource();
|
|
27871
|
-
var oldComputed = this._computed;
|
|
27872
|
-
if (newComputed !== oldComputed) {
|
|
27873
|
-
this._computed = newComputed;
|
|
27874
|
-
var parent_1 = this._parent;
|
|
27875
|
-
var oldImage = this._image;
|
|
27876
|
-
var onUpdateBound = this._onUpdateBound;
|
|
27877
|
-
if (newComputed instanceof pixi_js.Texture) {
|
|
27878
|
-
if (oldComputed instanceof pixi_js.Texture) {
|
|
27879
|
-
oldComputed.off("update", onUpdateBound);
|
|
27880
|
-
if (oldImage instanceof pixi_js.Sprite) {
|
|
27881
|
-
oldImage.texture = newComputed;
|
|
27882
|
-
newComputed.on("update", onUpdateBound);
|
|
27883
|
-
}
|
|
27884
|
-
}
|
|
27885
|
-
else {
|
|
27886
|
-
if (oldImage != null) {
|
|
27887
|
-
parent_1.removeChild(oldImage);
|
|
27888
|
-
}
|
|
27889
|
-
var newImage = new pixi_js.Sprite(newComputed);
|
|
27890
|
-
var overflowMask = parent_1.getOverflowMask();
|
|
27891
|
-
if (overflowMask) {
|
|
27892
|
-
newImage.mask = overflowMask;
|
|
27893
|
-
}
|
|
27894
|
-
newComputed.on("update", onUpdateBound);
|
|
27895
|
-
parent_1.addChild(newImage);
|
|
27896
|
-
this._image = newImage;
|
|
27897
|
-
}
|
|
27898
|
-
}
|
|
27899
|
-
else {
|
|
27900
|
-
if (oldComputed instanceof pixi_js.Texture) {
|
|
27901
|
-
oldComputed.off("update", onUpdateBound);
|
|
27902
|
-
if (oldImage != null) {
|
|
27903
|
-
parent_1.removeChild(oldImage);
|
|
27904
|
-
oldImage.destroy();
|
|
27905
|
-
}
|
|
27906
|
-
}
|
|
27907
|
-
else if (oldImage != null) {
|
|
27908
|
-
parent_1.removeChild(oldImage);
|
|
27909
|
-
}
|
|
27910
|
-
if (newComputed != null) {
|
|
27911
|
-
var overflowMask = parent_1.getOverflowMask();
|
|
27912
|
-
if (overflowMask) {
|
|
27913
|
-
newComputed.mask = overflowMask;
|
|
27914
|
-
}
|
|
27915
|
-
parent_1.addChild(newComputed);
|
|
27916
|
-
}
|
|
27917
|
-
this._image = newComputed;
|
|
27918
|
-
}
|
|
27919
|
-
return true;
|
|
27920
|
-
}
|
|
27921
|
-
return false;
|
|
27922
|
-
};
|
|
27923
|
-
DImagePiece.prototype.isRefitable = function (target) {
|
|
27924
|
-
return target != null && target === this._image;
|
|
27925
|
-
};
|
|
27926
|
-
DImagePiece.prototype.destroy = function () {
|
|
27927
|
-
var image = this._image;
|
|
27928
|
-
if (image) {
|
|
27929
|
-
this._image = null;
|
|
27930
|
-
var computed = this._computed;
|
|
27931
|
-
if (computed instanceof pixi_js.Texture) {
|
|
27932
|
-
computed.off("update", this._onUpdateBound, this);
|
|
27933
|
-
image.destroy();
|
|
27934
|
-
}
|
|
27935
|
-
}
|
|
27936
|
-
};
|
|
27937
|
-
DImagePiece.prototype.onUpdate = function () {
|
|
27938
|
-
this._parent.toDirty();
|
|
27939
|
-
DApplications.update(this._parent);
|
|
27940
|
-
};
|
|
27941
|
-
return DImagePiece;
|
|
27942
|
-
}());
|
|
27943
|
-
|
|
27944
27690
|
var DImagePieceLayouterPart = /** @class */ (function () {
|
|
27945
27691
|
function DImagePieceLayouterPart() {
|
|
27946
27692
|
this._pieces = [];
|
|
27693
|
+
this._bounds = [];
|
|
27947
27694
|
this._size = 0;
|
|
27948
27695
|
this._margin = 0;
|
|
27949
27696
|
}
|
|
@@ -27953,12 +27700,6 @@
|
|
|
27953
27700
|
this._margin = 0;
|
|
27954
27701
|
this._text = undefined;
|
|
27955
27702
|
};
|
|
27956
|
-
DImagePieceLayouterPart.prototype.add = function (image, size, margin) {
|
|
27957
|
-
var pieces = this._pieces;
|
|
27958
|
-
pieces.push(image);
|
|
27959
|
-
this._size += margin + size;
|
|
27960
|
-
this._margin = margin;
|
|
27961
|
-
};
|
|
27962
27703
|
DImagePieceLayouterPart.prototype.set = function (text) {
|
|
27963
27704
|
this._text = text;
|
|
27964
27705
|
};
|
|
@@ -27977,23 +27718,34 @@
|
|
|
27977
27718
|
function DImagePieceLayouterPartBottom() {
|
|
27978
27719
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
27979
27720
|
}
|
|
27721
|
+
DImagePieceLayouterPartBottom.prototype.add = function (image, bound, margin) {
|
|
27722
|
+
this._pieces.push(image);
|
|
27723
|
+
this._bounds.push(bound);
|
|
27724
|
+
this._size += margin + bound.height;
|
|
27725
|
+
this._margin = margin;
|
|
27726
|
+
};
|
|
27980
27727
|
DImagePieceLayouterPartBottom.prototype.execute = function (pbottom, height) {
|
|
27981
27728
|
var pieces = this._pieces;
|
|
27729
|
+
var bounds = this._bounds;
|
|
27982
27730
|
var y = height - pbottom;
|
|
27983
27731
|
if (this._text !== undefined) {
|
|
27984
27732
|
var margin = 0;
|
|
27985
27733
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
27986
27734
|
var piece = pieces[i];
|
|
27987
|
-
|
|
27988
|
-
|
|
27735
|
+
var bound = bounds[i];
|
|
27736
|
+
var object = piece.object;
|
|
27737
|
+
y -= margin + bound.height;
|
|
27738
|
+
object.y = y - bound.y;
|
|
27989
27739
|
margin = piece.margin.horizontal;
|
|
27990
27740
|
}
|
|
27991
27741
|
}
|
|
27992
27742
|
else {
|
|
27993
27743
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
27994
27744
|
var piece = pieces[i];
|
|
27995
|
-
|
|
27996
|
-
|
|
27745
|
+
var bound = bounds[i];
|
|
27746
|
+
var object = piece.object;
|
|
27747
|
+
y -= piece.margin.horizontal + bound.height;
|
|
27748
|
+
object.y = y - bound.y;
|
|
27997
27749
|
}
|
|
27998
27750
|
}
|
|
27999
27751
|
};
|
|
@@ -28005,17 +27757,20 @@
|
|
|
28005
27757
|
function DImagePieceLayouterPartCenter() {
|
|
28006
27758
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
28007
27759
|
}
|
|
28008
|
-
DImagePieceLayouterPartCenter.prototype.add = function (image,
|
|
27760
|
+
DImagePieceLayouterPartCenter.prototype.add = function (image, bound, margin) {
|
|
28009
27761
|
var pieces = this._pieces;
|
|
28010
27762
|
pieces.push(image);
|
|
28011
|
-
this._size = Math.max(this.size,
|
|
27763
|
+
this._size = Math.max(this.size, bound.width);
|
|
28012
27764
|
};
|
|
28013
27765
|
DImagePieceLayouterPartCenter.prototype.execute = function (pleft, pright, width) {
|
|
28014
27766
|
var c = pleft + (width - pleft - pright) * 0.5;
|
|
28015
27767
|
var pieces = this._pieces;
|
|
27768
|
+
var bounds = this._bounds;
|
|
28016
27769
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28017
27770
|
var piece = pieces[i];
|
|
28018
|
-
|
|
27771
|
+
var bound = bounds[i];
|
|
27772
|
+
var object = piece.object;
|
|
27773
|
+
object.x = c - bound.x - bound.width * 0.5;
|
|
28019
27774
|
}
|
|
28020
27775
|
};
|
|
28021
27776
|
return DImagePieceLayouterPartCenter;
|
|
@@ -28026,22 +27781,33 @@
|
|
|
28026
27781
|
function DImagePieceLayouterPartLeft() {
|
|
28027
27782
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
28028
27783
|
}
|
|
27784
|
+
DImagePieceLayouterPartLeft.prototype.add = function (image, bound, margin) {
|
|
27785
|
+
this._pieces.push(image);
|
|
27786
|
+
this._bounds.push(bound);
|
|
27787
|
+
this._size += margin + bound.width;
|
|
27788
|
+
this._margin = margin;
|
|
27789
|
+
};
|
|
28029
27790
|
DImagePieceLayouterPartLeft.prototype.execute = function (pleft) {
|
|
28030
27791
|
var pieces = this._pieces;
|
|
27792
|
+
var bounds = this._bounds;
|
|
28031
27793
|
var x = pleft;
|
|
28032
27794
|
if (this._text !== undefined) {
|
|
28033
27795
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28034
27796
|
var piece = pieces[i];
|
|
28035
|
-
|
|
28036
|
-
|
|
27797
|
+
var bound = bounds[i];
|
|
27798
|
+
var object = piece.object;
|
|
27799
|
+
object.x = x - bound.x;
|
|
27800
|
+
x += bound.width + piece.margin.horizontal;
|
|
28037
27801
|
}
|
|
28038
27802
|
}
|
|
28039
27803
|
else {
|
|
28040
27804
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28041
27805
|
var piece = pieces[i];
|
|
27806
|
+
var bound = bounds[i];
|
|
27807
|
+
var object = piece.object;
|
|
28042
27808
|
x += piece.margin.horizontal;
|
|
28043
|
-
|
|
28044
|
-
x +=
|
|
27809
|
+
object.x = x - bound.x;
|
|
27810
|
+
x += bound.width;
|
|
28045
27811
|
}
|
|
28046
27812
|
}
|
|
28047
27813
|
};
|
|
@@ -28053,17 +27819,20 @@
|
|
|
28053
27819
|
function DImagePieceLayouterPartMiddle() {
|
|
28054
27820
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
28055
27821
|
}
|
|
28056
|
-
DImagePieceLayouterPartMiddle.prototype.add = function (image,
|
|
28057
|
-
|
|
28058
|
-
|
|
28059
|
-
this._size = Math.max(this.size,
|
|
27822
|
+
DImagePieceLayouterPartMiddle.prototype.add = function (image, bound, margin) {
|
|
27823
|
+
this._pieces.push(image);
|
|
27824
|
+
this._bounds.push(bound);
|
|
27825
|
+
this._size = Math.max(this.size, bound.height);
|
|
28060
27826
|
};
|
|
28061
27827
|
DImagePieceLayouterPartMiddle.prototype.execute = function (ptop, pbottom, height) {
|
|
28062
27828
|
var c = ptop + (height - ptop - pbottom) * 0.5;
|
|
28063
27829
|
var pieces = this._pieces;
|
|
27830
|
+
var bounds = this._bounds;
|
|
28064
27831
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28065
27832
|
var piece = pieces[i];
|
|
28066
|
-
|
|
27833
|
+
var bound = bounds[i];
|
|
27834
|
+
var object = piece.object;
|
|
27835
|
+
object.y = c - bound.y - bound.height * 0.5;
|
|
28067
27836
|
}
|
|
28068
27837
|
};
|
|
28069
27838
|
return DImagePieceLayouterPartMiddle;
|
|
@@ -28074,23 +27843,34 @@
|
|
|
28074
27843
|
function DImagePieceLayouterPartRight() {
|
|
28075
27844
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
28076
27845
|
}
|
|
27846
|
+
DImagePieceLayouterPartRight.prototype.add = function (image, bound, margin) {
|
|
27847
|
+
this._pieces.push(image);
|
|
27848
|
+
this._bounds.push(bound);
|
|
27849
|
+
this._size += margin + bound.width;
|
|
27850
|
+
this._margin = margin;
|
|
27851
|
+
};
|
|
28077
27852
|
DImagePieceLayouterPartRight.prototype.execute = function (pright, width) {
|
|
28078
27853
|
var pieces = this._pieces;
|
|
27854
|
+
var bounds = this._bounds;
|
|
28079
27855
|
var x = width - pright;
|
|
28080
27856
|
if (this._text !== undefined) {
|
|
28081
27857
|
var margin = 0;
|
|
28082
27858
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28083
27859
|
var piece = pieces[i];
|
|
28084
|
-
|
|
28085
|
-
|
|
27860
|
+
var bound = bounds[i];
|
|
27861
|
+
var object = piece.object;
|
|
27862
|
+
x -= margin + bound.width;
|
|
27863
|
+
object.x = x - bound.x;
|
|
28086
27864
|
margin = piece.margin.horizontal;
|
|
28087
27865
|
}
|
|
28088
27866
|
}
|
|
28089
27867
|
else {
|
|
28090
27868
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28091
27869
|
var piece = pieces[i];
|
|
28092
|
-
|
|
28093
|
-
|
|
27870
|
+
var bound = bounds[i];
|
|
27871
|
+
var object = piece.object;
|
|
27872
|
+
x -= piece.margin.horizontal + bound.width;
|
|
27873
|
+
object.x = x - bound.x;
|
|
28094
27874
|
}
|
|
28095
27875
|
}
|
|
28096
27876
|
};
|
|
@@ -28102,24 +27882,35 @@
|
|
|
28102
27882
|
function DImagePieceLayouterPartTop() {
|
|
28103
27883
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
28104
27884
|
}
|
|
27885
|
+
DImagePieceLayouterPartTop.prototype.add = function (image, bound, margin) {
|
|
27886
|
+
this._pieces.push(image);
|
|
27887
|
+
this._bounds.push(bound);
|
|
27888
|
+
this._size += margin + bound.height;
|
|
27889
|
+
this._margin = margin;
|
|
27890
|
+
};
|
|
28105
27891
|
DImagePieceLayouterPartTop.prototype.execute = function (ptop) {
|
|
28106
27892
|
var pieces = this._pieces;
|
|
27893
|
+
var bounds = this._bounds;
|
|
28107
27894
|
var y = ptop;
|
|
28108
27895
|
if (this._text !== undefined) {
|
|
28109
27896
|
var margin = 0;
|
|
28110
27897
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28111
27898
|
var piece = pieces[i];
|
|
28112
|
-
|
|
28113
|
-
|
|
27899
|
+
var bound = bounds[i];
|
|
27900
|
+
var object = piece.object;
|
|
27901
|
+
object.y = margin + y - bound.y;
|
|
27902
|
+
y += bound.height;
|
|
28114
27903
|
margin = piece.margin.vertical;
|
|
28115
27904
|
}
|
|
28116
27905
|
}
|
|
28117
27906
|
else {
|
|
28118
27907
|
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
28119
27908
|
var piece = pieces[i];
|
|
27909
|
+
var bound = bounds[i];
|
|
27910
|
+
var object = piece.object;
|
|
28120
27911
|
y += piece.margin.vertical;
|
|
28121
|
-
|
|
28122
|
-
y +=
|
|
27912
|
+
object.y = y - bound.y;
|
|
27913
|
+
y += bound.height;
|
|
28123
27914
|
}
|
|
28124
27915
|
}
|
|
28125
27916
|
};
|
|
@@ -28145,35 +27936,31 @@
|
|
|
28145
27936
|
this.text = undefined;
|
|
28146
27937
|
};
|
|
28147
27938
|
DImagePieceLayouterPartContainer.prototype.add = function (image) {
|
|
28148
|
-
var
|
|
28149
|
-
if (
|
|
28150
|
-
var
|
|
28151
|
-
var
|
|
28152
|
-
var
|
|
28153
|
-
|
|
28154
|
-
var imageMarginHorizontal = imageMargin.horizontal;
|
|
28155
|
-
var imageMarginVertical = imageMargin.vertical;
|
|
28156
|
-
var imageAlign = image.align;
|
|
28157
|
-
switch (imageAlign.horizontal) {
|
|
27939
|
+
var object = image.object;
|
|
27940
|
+
if (object != null) {
|
|
27941
|
+
var bound = object.getLocalBounds();
|
|
27942
|
+
var margin = image.margin;
|
|
27943
|
+
var align = image.align;
|
|
27944
|
+
switch (align.horizontal) {
|
|
28158
27945
|
case DAlignHorizontal.LEFT:
|
|
28159
|
-
this.left.add(image,
|
|
27946
|
+
this.left.add(image, bound, margin.horizontal);
|
|
28160
27947
|
break;
|
|
28161
27948
|
case DAlignHorizontal.CENTER:
|
|
28162
|
-
this.center.add(image,
|
|
27949
|
+
this.center.add(image, bound, margin.horizontal);
|
|
28163
27950
|
break;
|
|
28164
27951
|
case DAlignHorizontal.RIGHT:
|
|
28165
|
-
this.right.add(image,
|
|
27952
|
+
this.right.add(image, bound, margin.horizontal);
|
|
28166
27953
|
break;
|
|
28167
27954
|
}
|
|
28168
|
-
switch (
|
|
27955
|
+
switch (align.vertical) {
|
|
28169
27956
|
case DAlignVertical.TOP:
|
|
28170
|
-
this.top.add(image,
|
|
27957
|
+
this.top.add(image, bound, margin.vertical);
|
|
28171
27958
|
break;
|
|
28172
27959
|
case DAlignVertical.MIDDLE:
|
|
28173
|
-
this.middle.add(image,
|
|
27960
|
+
this.middle.add(image, bound, margin.vertical);
|
|
28174
27961
|
break;
|
|
28175
27962
|
case DAlignVertical.BOTTOM:
|
|
28176
|
-
this.bottom.add(image,
|
|
27963
|
+
this.bottom.add(image, bound, margin.vertical);
|
|
28177
27964
|
break;
|
|
28178
27965
|
}
|
|
28179
27966
|
}
|
|
@@ -28319,8 +28106,8 @@
|
|
|
28319
28106
|
this.border.clear();
|
|
28320
28107
|
};
|
|
28321
28108
|
DImagePieceLayouter.prototype.add = function (image) {
|
|
28322
|
-
var
|
|
28323
|
-
if (
|
|
28109
|
+
var object = image.object;
|
|
28110
|
+
if (object) {
|
|
28324
28111
|
switch (image.align.with) {
|
|
28325
28112
|
case DAlignWith.TEXT:
|
|
28326
28113
|
this.text.add(image);
|
|
@@ -29820,12 +29607,20 @@
|
|
|
29820
29607
|
DApplications.update(this);
|
|
29821
29608
|
}
|
|
29822
29609
|
}
|
|
29823
|
-
else {
|
|
29610
|
+
else if (text.text !== formatted) {
|
|
29824
29611
|
text.text = formatted;
|
|
29825
29612
|
this.toDirty();
|
|
29826
29613
|
DApplications.update(this);
|
|
29827
29614
|
}
|
|
29828
29615
|
}
|
|
29616
|
+
else {
|
|
29617
|
+
var text = this._text;
|
|
29618
|
+
if (text != null && text.text !== "") {
|
|
29619
|
+
text.text = "";
|
|
29620
|
+
this.toDirty();
|
|
29621
|
+
DApplications.update(this);
|
|
29622
|
+
}
|
|
29623
|
+
}
|
|
29829
29624
|
};
|
|
29830
29625
|
DTextBase.prototype.newText = function () {
|
|
29831
29626
|
return new DDynamicText(this._textStyle);
|
|
@@ -29987,16 +29782,670 @@
|
|
|
29987
29782
|
return DTextBase;
|
|
29988
29783
|
}(DBase));
|
|
29989
29784
|
|
|
29785
|
+
var DImageBaseThemeWrapperOther = /** @class */ (function () {
|
|
29786
|
+
function DImageBaseThemeWrapperOther(theme) {
|
|
29787
|
+
this._theme = theme;
|
|
29788
|
+
}
|
|
29789
|
+
DImageBaseThemeWrapperOther.prototype.getImageAlignHorizontal = function () {
|
|
29790
|
+
return this._theme.getImageAlignHorizontal();
|
|
29791
|
+
};
|
|
29792
|
+
DImageBaseThemeWrapperOther.prototype.getImageAlignVertical = function () {
|
|
29793
|
+
return this._theme.getImageAlignVertical();
|
|
29794
|
+
};
|
|
29795
|
+
DImageBaseThemeWrapperOther.prototype.getImageAlignWith = function () {
|
|
29796
|
+
return this._theme.getImageAlignWith();
|
|
29797
|
+
};
|
|
29798
|
+
DImageBaseThemeWrapperOther.prototype.getImageMarginHorizontal = function () {
|
|
29799
|
+
return this._theme.getImageMarginHorizontal();
|
|
29800
|
+
};
|
|
29801
|
+
DImageBaseThemeWrapperOther.prototype.getImageMarginVertial = function () {
|
|
29802
|
+
return this._theme.getImageMarginVertial();
|
|
29803
|
+
};
|
|
29804
|
+
DImageBaseThemeWrapperOther.prototype.getImageTintColor = function (state) {
|
|
29805
|
+
return this._theme.getImageTintColor(state);
|
|
29806
|
+
};
|
|
29807
|
+
DImageBaseThemeWrapperOther.prototype.getImageTintAlpha = function (state) {
|
|
29808
|
+
return this._theme.getImageTintAlpha(state);
|
|
29809
|
+
};
|
|
29810
|
+
DImageBaseThemeWrapperOther.prototype.getImageRotation = function (state) {
|
|
29811
|
+
return this._theme.getImageRotation(state);
|
|
29812
|
+
};
|
|
29813
|
+
DImageBaseThemeWrapperOther.prototype.getImageSource = function (state) {
|
|
29814
|
+
return null;
|
|
29815
|
+
};
|
|
29816
|
+
return DImageBaseThemeWrapperOther;
|
|
29817
|
+
}());
|
|
29818
|
+
|
|
29819
|
+
var DImageBaseThemeWrapperSecondary = /** @class */ (function () {
|
|
29820
|
+
function DImageBaseThemeWrapperSecondary(theme) {
|
|
29821
|
+
this._theme = theme;
|
|
29822
|
+
}
|
|
29823
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageAlignHorizontal = function () {
|
|
29824
|
+
return this._theme.getSecondaryImageAlignHorizontal();
|
|
29825
|
+
};
|
|
29826
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageAlignVertical = function () {
|
|
29827
|
+
return this._theme.getSecondaryImageAlignVertical();
|
|
29828
|
+
};
|
|
29829
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageAlignWith = function () {
|
|
29830
|
+
return this._theme.getSecondaryImageAlignWith();
|
|
29831
|
+
};
|
|
29832
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageMarginHorizontal = function () {
|
|
29833
|
+
return this._theme.getSecondaryImageMarginHorizontal();
|
|
29834
|
+
};
|
|
29835
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageMarginVertial = function () {
|
|
29836
|
+
return this._theme.getSecondaryImageMarginVertial();
|
|
29837
|
+
};
|
|
29838
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageTintColor = function (state) {
|
|
29839
|
+
return this._theme.getSecondaryImageTintColor(state);
|
|
29840
|
+
};
|
|
29841
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageTintAlpha = function (state) {
|
|
29842
|
+
return this._theme.getSecondaryImageTintAlpha(state);
|
|
29843
|
+
};
|
|
29844
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageRotation = function (state) {
|
|
29845
|
+
return this._theme.getSecondaryImageRotation(state);
|
|
29846
|
+
};
|
|
29847
|
+
DImageBaseThemeWrapperSecondary.prototype.getImageSource = function (state) {
|
|
29848
|
+
var _a, _b, _c;
|
|
29849
|
+
return (_c = (_b = (_a = this._theme).getSecondaryImageSource) === null || _b === void 0 ? void 0 : _b.call(_a, state)) !== null && _c !== void 0 ? _c : null;
|
|
29850
|
+
};
|
|
29851
|
+
return DImageBaseThemeWrapperSecondary;
|
|
29852
|
+
}());
|
|
29853
|
+
|
|
29854
|
+
var DImageBaseThemeWrapperTertiary = /** @class */ (function () {
|
|
29855
|
+
function DImageBaseThemeWrapperTertiary(theme) {
|
|
29856
|
+
this._theme = theme;
|
|
29857
|
+
}
|
|
29858
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageAlignHorizontal = function () {
|
|
29859
|
+
return this._theme.getTertiaryImageAlignHorizontal();
|
|
29860
|
+
};
|
|
29861
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageAlignVertical = function () {
|
|
29862
|
+
return this._theme.getTertiaryImageAlignVertical();
|
|
29863
|
+
};
|
|
29864
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageAlignWith = function () {
|
|
29865
|
+
return this._theme.getTertiaryImageAlignWith();
|
|
29866
|
+
};
|
|
29867
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageMarginHorizontal = function () {
|
|
29868
|
+
return this._theme.getTertiaryImageMarginHorizontal();
|
|
29869
|
+
};
|
|
29870
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageMarginVertial = function () {
|
|
29871
|
+
return this._theme.getTertiaryImageMarginVertial();
|
|
29872
|
+
};
|
|
29873
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageTintColor = function (state) {
|
|
29874
|
+
return this._theme.getTertiaryImageTintColor(state);
|
|
29875
|
+
};
|
|
29876
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageTintAlpha = function (state) {
|
|
29877
|
+
return this._theme.getTertiaryImageTintAlpha(state);
|
|
29878
|
+
};
|
|
29879
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageRotation = function (state) {
|
|
29880
|
+
return this._theme.getTertiaryImageRotation(state);
|
|
29881
|
+
};
|
|
29882
|
+
DImageBaseThemeWrapperTertiary.prototype.getImageSource = function (state) {
|
|
29883
|
+
var _a, _b, _c;
|
|
29884
|
+
return (_c = (_b = (_a = this._theme).getTertiaryImageSource) === null || _b === void 0 ? void 0 : _b.call(_a, state)) !== null && _c !== void 0 ? _c : null;
|
|
29885
|
+
};
|
|
29886
|
+
return DImageBaseThemeWrapperTertiary;
|
|
29887
|
+
}());
|
|
29888
|
+
|
|
29889
|
+
var DImagePieceTintImpl = /** @class */ (function () {
|
|
29890
|
+
function DImagePieceTintImpl(parent, theme, options) {
|
|
29891
|
+
this._parent = parent;
|
|
29892
|
+
if (options != null) {
|
|
29893
|
+
this._color = options.color;
|
|
29894
|
+
this._alpha = options.alpha;
|
|
29895
|
+
}
|
|
29896
|
+
this._theme = theme;
|
|
29897
|
+
}
|
|
29898
|
+
Object.defineProperty(DImagePieceTintImpl.prototype, "color", {
|
|
29899
|
+
get: function () {
|
|
29900
|
+
return this._color;
|
|
29901
|
+
},
|
|
29902
|
+
set: function (color) {
|
|
29903
|
+
if (this._color !== color) {
|
|
29904
|
+
this._color = color;
|
|
29905
|
+
this.onChange();
|
|
29906
|
+
}
|
|
29907
|
+
},
|
|
29908
|
+
enumerable: false,
|
|
29909
|
+
configurable: true
|
|
29910
|
+
});
|
|
29911
|
+
DImagePieceTintImpl.prototype.getColor = function (state) {
|
|
29912
|
+
var color = this._color;
|
|
29913
|
+
if (color !== undefined) {
|
|
29914
|
+
if (isFunction(color)) {
|
|
29915
|
+
var result = color(state);
|
|
29916
|
+
if (result !== undefined) {
|
|
29917
|
+
return result;
|
|
29918
|
+
}
|
|
29919
|
+
}
|
|
29920
|
+
else {
|
|
29921
|
+
return color;
|
|
29922
|
+
}
|
|
29923
|
+
}
|
|
29924
|
+
return this._theme.getImageTintColor(state);
|
|
29925
|
+
};
|
|
29926
|
+
Object.defineProperty(DImagePieceTintImpl.prototype, "alpha", {
|
|
29927
|
+
get: function () {
|
|
29928
|
+
return this._alpha;
|
|
29929
|
+
},
|
|
29930
|
+
set: function (alpha) {
|
|
29931
|
+
if (this._alpha !== alpha) {
|
|
29932
|
+
this._alpha = alpha;
|
|
29933
|
+
this.onChange();
|
|
29934
|
+
}
|
|
29935
|
+
},
|
|
29936
|
+
enumerable: false,
|
|
29937
|
+
configurable: true
|
|
29938
|
+
});
|
|
29939
|
+
DImagePieceTintImpl.prototype.getAlpha = function (state) {
|
|
29940
|
+
var alpha = this._alpha;
|
|
29941
|
+
if (alpha !== undefined) {
|
|
29942
|
+
if (isFunction(alpha)) {
|
|
29943
|
+
var result = alpha(state);
|
|
29944
|
+
if (result !== undefined) {
|
|
29945
|
+
return result;
|
|
29946
|
+
}
|
|
29947
|
+
}
|
|
29948
|
+
else {
|
|
29949
|
+
return alpha;
|
|
29950
|
+
}
|
|
29951
|
+
}
|
|
29952
|
+
return this._theme.getImageTintAlpha(state);
|
|
29953
|
+
};
|
|
29954
|
+
DImagePieceTintImpl.prototype.set = function (color, alpha) {
|
|
29955
|
+
var isChanged = false;
|
|
29956
|
+
if (color != null && this._color !== color) {
|
|
29957
|
+
this._color = color;
|
|
29958
|
+
isChanged = true;
|
|
29959
|
+
}
|
|
29960
|
+
if (alpha != null && this._alpha !== alpha) {
|
|
29961
|
+
this._alpha = alpha;
|
|
29962
|
+
isChanged = true;
|
|
29963
|
+
}
|
|
29964
|
+
if (isChanged) {
|
|
29965
|
+
this.onChange();
|
|
29966
|
+
}
|
|
29967
|
+
return this;
|
|
29968
|
+
};
|
|
29969
|
+
DImagePieceTintImpl.prototype.onChange = function () {
|
|
29970
|
+
this._parent.updateTint();
|
|
29971
|
+
DApplications.update(this._parent);
|
|
29972
|
+
};
|
|
29973
|
+
return DImagePieceTintImpl;
|
|
29974
|
+
}());
|
|
29975
|
+
|
|
29976
|
+
var DImagePieceMarginImpl = /** @class */ (function () {
|
|
29977
|
+
function DImagePieceMarginImpl(parent, theme, options) {
|
|
29978
|
+
var _a, _b;
|
|
29979
|
+
this._parent = parent;
|
|
29980
|
+
this._vertical = (_a = options === null || options === void 0 ? void 0 : options.vertical) !== null && _a !== void 0 ? _a : theme.getImageMarginVertial();
|
|
29981
|
+
this._horizontal = (_b = options === null || options === void 0 ? void 0 : options.horizontal) !== null && _b !== void 0 ? _b : theme.getImageMarginHorizontal();
|
|
29982
|
+
}
|
|
29983
|
+
Object.defineProperty(DImagePieceMarginImpl.prototype, "vertical", {
|
|
29984
|
+
get: function () {
|
|
29985
|
+
return this._vertical;
|
|
29986
|
+
},
|
|
29987
|
+
set: function (vertical) {
|
|
29988
|
+
if (this._vertical !== vertical) {
|
|
29989
|
+
this._vertical = vertical;
|
|
29990
|
+
this.onChange();
|
|
29991
|
+
}
|
|
29992
|
+
},
|
|
29993
|
+
enumerable: false,
|
|
29994
|
+
configurable: true
|
|
29995
|
+
});
|
|
29996
|
+
Object.defineProperty(DImagePieceMarginImpl.prototype, "horizontal", {
|
|
29997
|
+
get: function () {
|
|
29998
|
+
return this._horizontal;
|
|
29999
|
+
},
|
|
30000
|
+
set: function (horizontal) {
|
|
30001
|
+
if (this._horizontal !== horizontal) {
|
|
30002
|
+
this._horizontal = horizontal;
|
|
30003
|
+
this.onChange();
|
|
30004
|
+
}
|
|
30005
|
+
},
|
|
30006
|
+
enumerable: false,
|
|
30007
|
+
configurable: true
|
|
30008
|
+
});
|
|
30009
|
+
DImagePieceMarginImpl.prototype.set = function (vertical, horizontal) {
|
|
30010
|
+
var isChanged = false;
|
|
30011
|
+
if (vertical != null && this._vertical !== vertical) {
|
|
30012
|
+
this._vertical = vertical;
|
|
30013
|
+
isChanged = true;
|
|
30014
|
+
}
|
|
30015
|
+
if (horizontal != null && this._horizontal !== horizontal) {
|
|
30016
|
+
this._horizontal = horizontal;
|
|
30017
|
+
isChanged = true;
|
|
30018
|
+
}
|
|
30019
|
+
if (isChanged) {
|
|
30020
|
+
this.onChange();
|
|
30021
|
+
}
|
|
30022
|
+
return this;
|
|
30023
|
+
};
|
|
30024
|
+
DImagePieceMarginImpl.prototype.onChange = function () {
|
|
30025
|
+
this._parent.onUpdate();
|
|
30026
|
+
};
|
|
30027
|
+
return DImagePieceMarginImpl;
|
|
30028
|
+
}());
|
|
30029
|
+
|
|
30030
|
+
var DImagePieceAlignImpl = /** @class */ (function () {
|
|
30031
|
+
function DImagePieceAlignImpl(parent, theme, options) {
|
|
30032
|
+
var _a, _b, _c;
|
|
30033
|
+
this._parent = parent;
|
|
30034
|
+
this._with = toEnum((_a = options === null || options === void 0 ? void 0 : options.with) !== null && _a !== void 0 ? _a : theme.getImageAlignWith(), DAlignWith);
|
|
30035
|
+
this._vertical = toEnum((_b = options === null || options === void 0 ? void 0 : options.vertical) !== null && _b !== void 0 ? _b : theme.getImageAlignVertical(), DAlignVertical);
|
|
30036
|
+
this._horizontal = toEnum((_c = options === null || options === void 0 ? void 0 : options.horizontal) !== null && _c !== void 0 ? _c : theme.getImageAlignHorizontal(), DAlignHorizontal);
|
|
30037
|
+
}
|
|
30038
|
+
Object.defineProperty(DImagePieceAlignImpl.prototype, "with", {
|
|
30039
|
+
get: function () {
|
|
30040
|
+
return this._with;
|
|
30041
|
+
},
|
|
30042
|
+
set: function (w) {
|
|
30043
|
+
w = toEnum(w, DAlignWith);
|
|
30044
|
+
if (this._with !== w) {
|
|
30045
|
+
this._with = w;
|
|
30046
|
+
this.onChange();
|
|
30047
|
+
}
|
|
30048
|
+
},
|
|
30049
|
+
enumerable: false,
|
|
30050
|
+
configurable: true
|
|
30051
|
+
});
|
|
30052
|
+
Object.defineProperty(DImagePieceAlignImpl.prototype, "vertical", {
|
|
30053
|
+
get: function () {
|
|
30054
|
+
return this._vertical;
|
|
30055
|
+
},
|
|
30056
|
+
set: function (vertical) {
|
|
30057
|
+
vertical = toEnum(vertical, DAlignVertical);
|
|
30058
|
+
if (this._vertical !== vertical) {
|
|
30059
|
+
this._vertical = vertical;
|
|
30060
|
+
this.onChange();
|
|
30061
|
+
}
|
|
30062
|
+
},
|
|
30063
|
+
enumerable: false,
|
|
30064
|
+
configurable: true
|
|
30065
|
+
});
|
|
30066
|
+
Object.defineProperty(DImagePieceAlignImpl.prototype, "horizontal", {
|
|
30067
|
+
get: function () {
|
|
30068
|
+
return this._horizontal;
|
|
30069
|
+
},
|
|
30070
|
+
set: function (horizontal) {
|
|
30071
|
+
horizontal = toEnum(horizontal, DAlignHorizontal);
|
|
30072
|
+
if (this._horizontal !== horizontal) {
|
|
30073
|
+
this._horizontal = horizontal;
|
|
30074
|
+
this.onChange();
|
|
30075
|
+
}
|
|
30076
|
+
},
|
|
30077
|
+
enumerable: false,
|
|
30078
|
+
configurable: true
|
|
30079
|
+
});
|
|
30080
|
+
DImagePieceAlignImpl.prototype.set = function (w, vertical, horizontal) {
|
|
30081
|
+
var isChanged = false;
|
|
30082
|
+
if (w != null) {
|
|
30083
|
+
w = toEnum(w, DAlignWith);
|
|
30084
|
+
if (this._with !== w) {
|
|
30085
|
+
this._with = w;
|
|
30086
|
+
isChanged = true;
|
|
30087
|
+
}
|
|
30088
|
+
}
|
|
30089
|
+
if (vertical != null) {
|
|
30090
|
+
vertical = toEnum(vertical, DAlignVertical);
|
|
30091
|
+
if (this._vertical !== vertical) {
|
|
30092
|
+
this._vertical = vertical;
|
|
30093
|
+
isChanged = true;
|
|
30094
|
+
}
|
|
30095
|
+
}
|
|
30096
|
+
if (horizontal != null) {
|
|
30097
|
+
horizontal = toEnum(horizontal, DAlignHorizontal);
|
|
30098
|
+
if (this._horizontal !== horizontal) {
|
|
30099
|
+
this._horizontal = horizontal;
|
|
30100
|
+
isChanged = true;
|
|
30101
|
+
}
|
|
30102
|
+
}
|
|
30103
|
+
if (isChanged) {
|
|
30104
|
+
this.onChange();
|
|
30105
|
+
}
|
|
30106
|
+
return this;
|
|
30107
|
+
};
|
|
30108
|
+
DImagePieceAlignImpl.prototype.onChange = function () {
|
|
30109
|
+
this._parent.onUpdate();
|
|
30110
|
+
};
|
|
30111
|
+
return DImagePieceAlignImpl;
|
|
30112
|
+
}());
|
|
30113
|
+
|
|
30114
|
+
var DImagePieceImpl = /** @class */ (function () {
|
|
30115
|
+
function DImagePieceImpl(parent, theme, options) {
|
|
30116
|
+
var _this = this;
|
|
30117
|
+
this._parent = parent;
|
|
30118
|
+
this._theme = theme;
|
|
30119
|
+
this._object = null;
|
|
30120
|
+
this._align = new DImagePieceAlignImpl(this, theme, options === null || options === void 0 ? void 0 : options.align);
|
|
30121
|
+
this._margin = new DImagePieceMarginImpl(this, theme, options === null || options === void 0 ? void 0 : options.margin);
|
|
30122
|
+
this._tint = new DImagePieceTintImpl(this, theme, options === null || options === void 0 ? void 0 : options.tint);
|
|
30123
|
+
this._rotation = options === null || options === void 0 ? void 0 : options.rotation;
|
|
30124
|
+
this._source = options === null || options === void 0 ? void 0 : options.source;
|
|
30125
|
+
this._computed = null;
|
|
30126
|
+
this._onUpdateBound = function () {
|
|
30127
|
+
_this.onUpdate();
|
|
30128
|
+
};
|
|
30129
|
+
}
|
|
30130
|
+
Object.defineProperty(DImagePieceImpl.prototype, "object", {
|
|
30131
|
+
get: function () {
|
|
30132
|
+
return this._object;
|
|
30133
|
+
},
|
|
30134
|
+
enumerable: false,
|
|
30135
|
+
configurable: true
|
|
30136
|
+
});
|
|
30137
|
+
Object.defineProperty(DImagePieceImpl.prototype, "align", {
|
|
30138
|
+
get: function () {
|
|
30139
|
+
return this._align;
|
|
30140
|
+
},
|
|
30141
|
+
enumerable: false,
|
|
30142
|
+
configurable: true
|
|
30143
|
+
});
|
|
30144
|
+
Object.defineProperty(DImagePieceImpl.prototype, "margin", {
|
|
30145
|
+
get: function () {
|
|
30146
|
+
return this._margin;
|
|
30147
|
+
},
|
|
30148
|
+
enumerable: false,
|
|
30149
|
+
configurable: true
|
|
30150
|
+
});
|
|
30151
|
+
Object.defineProperty(DImagePieceImpl.prototype, "tint", {
|
|
30152
|
+
get: function () {
|
|
30153
|
+
return this._tint;
|
|
30154
|
+
},
|
|
30155
|
+
enumerable: false,
|
|
30156
|
+
configurable: true
|
|
30157
|
+
});
|
|
30158
|
+
Object.defineProperty(DImagePieceImpl.prototype, "source", {
|
|
30159
|
+
get: function () {
|
|
30160
|
+
return this._source;
|
|
30161
|
+
},
|
|
30162
|
+
set: function (source) {
|
|
30163
|
+
if (this._source !== source) {
|
|
30164
|
+
this._source = source;
|
|
30165
|
+
if (this.updateSource()) {
|
|
30166
|
+
this.onUpdate();
|
|
30167
|
+
}
|
|
30168
|
+
}
|
|
30169
|
+
},
|
|
30170
|
+
enumerable: false,
|
|
30171
|
+
configurable: true
|
|
30172
|
+
});
|
|
30173
|
+
Object.defineProperty(DImagePieceImpl.prototype, "rotation", {
|
|
30174
|
+
get: function () {
|
|
30175
|
+
return this._rotation;
|
|
30176
|
+
},
|
|
30177
|
+
set: function (rotation) {
|
|
30178
|
+
if (this._rotation !== rotation) {
|
|
30179
|
+
this._rotation = rotation;
|
|
30180
|
+
if (this.updateRotation()) {
|
|
30181
|
+
DApplications.update(this._parent);
|
|
30182
|
+
}
|
|
30183
|
+
}
|
|
30184
|
+
},
|
|
30185
|
+
enumerable: false,
|
|
30186
|
+
configurable: true
|
|
30187
|
+
});
|
|
30188
|
+
DImagePieceImpl.prototype.computeSource = function () {
|
|
30189
|
+
var source = this._source;
|
|
30190
|
+
if (source !== undefined) {
|
|
30191
|
+
if (isFunction(source)) {
|
|
30192
|
+
var result = source(this._parent.state);
|
|
30193
|
+
if (result !== undefined) {
|
|
30194
|
+
return result;
|
|
30195
|
+
}
|
|
30196
|
+
}
|
|
30197
|
+
else {
|
|
30198
|
+
return source;
|
|
30199
|
+
}
|
|
30200
|
+
}
|
|
30201
|
+
return this._theme.getImageSource(this._parent.state);
|
|
30202
|
+
};
|
|
30203
|
+
DImagePieceImpl.prototype.onStateChange = function (newState, oldState) {
|
|
30204
|
+
this.updateTint();
|
|
30205
|
+
this.updateRotation();
|
|
30206
|
+
};
|
|
30207
|
+
DImagePieceImpl.prototype.isTintAware = function (target) {
|
|
30208
|
+
return target != null && "tint" in target;
|
|
30209
|
+
};
|
|
30210
|
+
/**
|
|
30211
|
+
* Updates the tint.
|
|
30212
|
+
*
|
|
30213
|
+
* @returns True if the tint is changed.
|
|
30214
|
+
*/
|
|
30215
|
+
DImagePieceImpl.prototype.updateTint = function () {
|
|
30216
|
+
var object = this._object;
|
|
30217
|
+
if (object) {
|
|
30218
|
+
if (this.isTintAware(object)) {
|
|
30219
|
+
var state = this._parent.state;
|
|
30220
|
+
var color = this._tint.getColor(state);
|
|
30221
|
+
if (color != null) {
|
|
30222
|
+
var result = false;
|
|
30223
|
+
if (object.tint !== color) {
|
|
30224
|
+
object.tint = color;
|
|
30225
|
+
result = true;
|
|
30226
|
+
}
|
|
30227
|
+
var alpha = this._tint.getAlpha(state);
|
|
30228
|
+
if (object.alpha !== alpha) {
|
|
30229
|
+
object.alpha = alpha;
|
|
30230
|
+
result = true;
|
|
30231
|
+
}
|
|
30232
|
+
return result;
|
|
30233
|
+
}
|
|
30234
|
+
}
|
|
30235
|
+
}
|
|
30236
|
+
return false;
|
|
30237
|
+
};
|
|
30238
|
+
DImagePieceImpl.prototype.toRotation = function (theme, state) {
|
|
30239
|
+
var rotation = this._rotation;
|
|
30240
|
+
if (rotation != null) {
|
|
30241
|
+
if (isFunction(rotation)) {
|
|
30242
|
+
var result = rotation(state);
|
|
30243
|
+
if (result !== undefined) {
|
|
30244
|
+
return result;
|
|
30245
|
+
}
|
|
30246
|
+
}
|
|
30247
|
+
else {
|
|
30248
|
+
return rotation;
|
|
30249
|
+
}
|
|
30250
|
+
}
|
|
30251
|
+
return theme.getImageRotation(state);
|
|
30252
|
+
};
|
|
30253
|
+
DImagePieceImpl.prototype.updateRotation = function () {
|
|
30254
|
+
var object = this._object;
|
|
30255
|
+
if (object) {
|
|
30256
|
+
var theme = this._theme;
|
|
30257
|
+
var state = this._parent.state;
|
|
30258
|
+
var rotation = this.toRotation(theme, state);
|
|
30259
|
+
if (rotation != null) {
|
|
30260
|
+
var transform = object.transform;
|
|
30261
|
+
if (transform.rotation !== rotation) {
|
|
30262
|
+
transform.rotation = rotation;
|
|
30263
|
+
return true;
|
|
30264
|
+
}
|
|
30265
|
+
}
|
|
30266
|
+
}
|
|
30267
|
+
return false;
|
|
30268
|
+
};
|
|
30269
|
+
/**
|
|
30270
|
+
* Updates the computed source.
|
|
30271
|
+
*
|
|
30272
|
+
* @returns True if the computed source is changed
|
|
30273
|
+
*/
|
|
30274
|
+
DImagePieceImpl.prototype.updateSource = function () {
|
|
30275
|
+
var newComputed = this.computeSource();
|
|
30276
|
+
var oldComputed = this._computed;
|
|
30277
|
+
if (newComputed !== oldComputed) {
|
|
30278
|
+
this._computed = newComputed;
|
|
30279
|
+
var parent_1 = this._parent;
|
|
30280
|
+
var oldObject = this._object;
|
|
30281
|
+
var onUpdateBound = this._onUpdateBound;
|
|
30282
|
+
if (newComputed instanceof pixi_js.Texture) {
|
|
30283
|
+
if (oldComputed instanceof pixi_js.Texture) {
|
|
30284
|
+
oldComputed.off("update", onUpdateBound);
|
|
30285
|
+
if (oldObject instanceof pixi_js.Sprite) {
|
|
30286
|
+
oldObject.texture = newComputed;
|
|
30287
|
+
newComputed.on("update", onUpdateBound);
|
|
30288
|
+
}
|
|
30289
|
+
}
|
|
30290
|
+
else {
|
|
30291
|
+
if (oldObject != null) {
|
|
30292
|
+
parent_1.removeChild(oldObject);
|
|
30293
|
+
}
|
|
30294
|
+
var newObject = new pixi_js.Sprite(newComputed);
|
|
30295
|
+
newObject.anchor.set(0.5, 0.5);
|
|
30296
|
+
var overflowMask = parent_1.getOverflowMask();
|
|
30297
|
+
if (overflowMask) {
|
|
30298
|
+
newObject.mask = overflowMask;
|
|
30299
|
+
}
|
|
30300
|
+
newComputed.on("update", onUpdateBound);
|
|
30301
|
+
parent_1.addChild(newObject);
|
|
30302
|
+
this._object = newObject;
|
|
30303
|
+
}
|
|
30304
|
+
}
|
|
30305
|
+
else {
|
|
30306
|
+
if (oldComputed instanceof pixi_js.Texture) {
|
|
30307
|
+
oldComputed.off("update", onUpdateBound);
|
|
30308
|
+
if (oldObject != null) {
|
|
30309
|
+
parent_1.removeChild(oldObject);
|
|
30310
|
+
oldObject.destroy();
|
|
30311
|
+
}
|
|
30312
|
+
}
|
|
30313
|
+
else if (oldObject != null) {
|
|
30314
|
+
parent_1.removeChild(oldObject);
|
|
30315
|
+
}
|
|
30316
|
+
if (newComputed != null) {
|
|
30317
|
+
var overflowMask = parent_1.getOverflowMask();
|
|
30318
|
+
if (overflowMask) {
|
|
30319
|
+
newComputed.mask = overflowMask;
|
|
30320
|
+
}
|
|
30321
|
+
parent_1.addChild(newComputed);
|
|
30322
|
+
}
|
|
30323
|
+
this._object = newComputed;
|
|
30324
|
+
}
|
|
30325
|
+
return true;
|
|
30326
|
+
}
|
|
30327
|
+
return false;
|
|
30328
|
+
};
|
|
30329
|
+
DImagePieceImpl.prototype.isRefitable = function (target) {
|
|
30330
|
+
return target != null && target === this._object;
|
|
30331
|
+
};
|
|
30332
|
+
DImagePieceImpl.prototype.destroy = function () {
|
|
30333
|
+
this.source = null;
|
|
30334
|
+
};
|
|
30335
|
+
DImagePieceImpl.prototype.onUpdate = function () {
|
|
30336
|
+
this._parent.toDirty();
|
|
30337
|
+
DApplications.update(this._parent);
|
|
30338
|
+
};
|
|
30339
|
+
return DImagePieceImpl;
|
|
30340
|
+
}());
|
|
30341
|
+
|
|
30342
|
+
var DImagePieceContainerImpl = /** @class */ (function () {
|
|
30343
|
+
function DImagePieceContainerImpl(parent, theme, options) {
|
|
30344
|
+
this._parent = parent;
|
|
30345
|
+
this._theme = theme;
|
|
30346
|
+
var pieces = [];
|
|
30347
|
+
this._pieces = pieces;
|
|
30348
|
+
if (options != null) {
|
|
30349
|
+
var images = options.images;
|
|
30350
|
+
if (images != null) {
|
|
30351
|
+
pieces.push(this.newImage(theme, 0 < images.length ? images[0] : undefined));
|
|
30352
|
+
if (theme.getSecondaryImageSource != null || 1 < images.length) {
|
|
30353
|
+
pieces.push(this.newImage(new DImageBaseThemeWrapperSecondary(theme), images[1]));
|
|
30354
|
+
}
|
|
30355
|
+
if (theme.getTertiaryImageSource != null || 2 < images.length) {
|
|
30356
|
+
pieces.push(this.newImage(new DImageBaseThemeWrapperTertiary(theme), images[2]));
|
|
30357
|
+
}
|
|
30358
|
+
if (3 < images.length) {
|
|
30359
|
+
var other = new DImageBaseThemeWrapperOther(theme);
|
|
30360
|
+
for (var i = 3, imax = images.length; i < imax; ++i) {
|
|
30361
|
+
pieces.push(this.newImage(other, images[i]));
|
|
30362
|
+
}
|
|
30363
|
+
}
|
|
30364
|
+
}
|
|
30365
|
+
else {
|
|
30366
|
+
pieces.push(this.newImage(theme, options.image));
|
|
30367
|
+
if (theme.getSecondaryImageSource != null) {
|
|
30368
|
+
pieces.push(this.newImage(new DImageBaseThemeWrapperSecondary(theme)));
|
|
30369
|
+
}
|
|
30370
|
+
if (theme.getTertiaryImageSource != null) {
|
|
30371
|
+
pieces.push(this.newImage(new DImageBaseThemeWrapperTertiary(theme)));
|
|
30372
|
+
}
|
|
30373
|
+
}
|
|
30374
|
+
}
|
|
30375
|
+
else {
|
|
30376
|
+
pieces.push(this.newImage(theme));
|
|
30377
|
+
if (theme.getSecondaryImageSource != null) {
|
|
30378
|
+
pieces.push(this.newImage(new DImageBaseThemeWrapperSecondary(theme)));
|
|
30379
|
+
}
|
|
30380
|
+
if (theme.getTertiaryImageSource != null) {
|
|
30381
|
+
pieces.push(this.newImage(new DImageBaseThemeWrapperTertiary(theme)));
|
|
30382
|
+
}
|
|
30383
|
+
}
|
|
30384
|
+
}
|
|
30385
|
+
DImagePieceContainerImpl.prototype.newImage = function (theme, options) {
|
|
30386
|
+
return new DImagePieceImpl(this._parent, theme, options);
|
|
30387
|
+
};
|
|
30388
|
+
DImagePieceContainerImpl.prototype.onStateChange = function (newState, oldState) {
|
|
30389
|
+
var pieces = this._pieces;
|
|
30390
|
+
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
30391
|
+
pieces[i].onStateChange(newState, oldState);
|
|
30392
|
+
}
|
|
30393
|
+
};
|
|
30394
|
+
DImagePieceContainerImpl.prototype.isRefitable = function (target) {
|
|
30395
|
+
var pieces = this._pieces;
|
|
30396
|
+
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
30397
|
+
if (pieces[i].isRefitable(target)) {
|
|
30398
|
+
return true;
|
|
30399
|
+
}
|
|
30400
|
+
}
|
|
30401
|
+
return false;
|
|
30402
|
+
};
|
|
30403
|
+
DImagePieceContainerImpl.prototype.updateTextAndImage = function (layouter) {
|
|
30404
|
+
var pieces = this._pieces;
|
|
30405
|
+
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
30406
|
+
var piece = pieces[i];
|
|
30407
|
+
piece.updateSource();
|
|
30408
|
+
piece.updateTint();
|
|
30409
|
+
piece.updateRotation();
|
|
30410
|
+
layouter.add(piece);
|
|
30411
|
+
}
|
|
30412
|
+
};
|
|
30413
|
+
DImagePieceContainerImpl.prototype.add = function (options) {
|
|
30414
|
+
var result = this.newImage(this._theme, options);
|
|
30415
|
+
this._pieces.push(result);
|
|
30416
|
+
return result;
|
|
30417
|
+
};
|
|
30418
|
+
DImagePieceContainerImpl.prototype.get = function (index) {
|
|
30419
|
+
var pieces = this._pieces;
|
|
30420
|
+
if (0 <= index && index < pieces.length) {
|
|
30421
|
+
return pieces[index];
|
|
30422
|
+
}
|
|
30423
|
+
return null;
|
|
30424
|
+
};
|
|
30425
|
+
DImagePieceContainerImpl.prototype.remove = function (index) {
|
|
30426
|
+
var pieces = this._pieces;
|
|
30427
|
+
if (0 <= index && index < pieces.length) {
|
|
30428
|
+
pieces[index].destroy();
|
|
30429
|
+
return true;
|
|
30430
|
+
}
|
|
30431
|
+
return false;
|
|
30432
|
+
};
|
|
30433
|
+
DImagePieceContainerImpl.prototype.size = function () {
|
|
30434
|
+
return this._pieces.length;
|
|
30435
|
+
};
|
|
30436
|
+
DImagePieceContainerImpl.prototype.destroy = function () {
|
|
30437
|
+
var pieces = this._pieces;
|
|
30438
|
+
for (var i = 0, imax = pieces.length; i < imax; ++i) {
|
|
30439
|
+
pieces[i].destroy();
|
|
30440
|
+
}
|
|
30441
|
+
};
|
|
30442
|
+
return DImagePieceContainerImpl;
|
|
30443
|
+
}());
|
|
30444
|
+
|
|
29990
30445
|
/*
|
|
29991
30446
|
* Copyright (C) 2019 Toshiba Corporation
|
|
29992
30447
|
* SPDX-License-Identifier: Apache-2.0
|
|
29993
30448
|
*/
|
|
29994
|
-
var hasSecondaryImageSource = function (theme) {
|
|
29995
|
-
return !!theme.getSecondaryImageSource;
|
|
29996
|
-
};
|
|
29997
|
-
var hasTertiaryImageSource = function (theme) {
|
|
29998
|
-
return !!theme.getTertiaryImageSource;
|
|
29999
|
-
};
|
|
30000
30449
|
/**
|
|
30001
30450
|
* A base class for UI classes with an image support.
|
|
30002
30451
|
* See {@link DImageBaseEvents} for event details.
|
|
@@ -30007,44 +30456,33 @@
|
|
|
30007
30456
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
30008
30457
|
}
|
|
30009
30458
|
DImageBase.prototype.init = function (options) {
|
|
30010
|
-
this.
|
|
30459
|
+
this.getImage();
|
|
30011
30460
|
_super.prototype.init.call(this, options);
|
|
30012
30461
|
};
|
|
30013
|
-
DImageBase.prototype.newImages = function (theme, options) {
|
|
30014
|
-
var images = [];
|
|
30015
|
-
images.push(this.newImage(theme, this.toImageOptions(theme, options === null || options === void 0 ? void 0 : options.image)));
|
|
30016
|
-
if (hasSecondaryImageSource(theme)) {
|
|
30017
|
-
images.push(this.newImage(new DImageBaseThemeWrapperSecondary(theme)));
|
|
30018
|
-
}
|
|
30019
|
-
if (hasTertiaryImageSource(theme)) {
|
|
30020
|
-
images.push(this.newImage(new DImageBaseThemeWrapperTertiary(theme)));
|
|
30021
|
-
}
|
|
30022
|
-
return images;
|
|
30023
|
-
};
|
|
30024
|
-
DImageBase.prototype.toImageOptions = function (theme, options) {
|
|
30025
|
-
return options;
|
|
30026
|
-
};
|
|
30027
|
-
DImageBase.prototype.newImage = function (theme, options) {
|
|
30028
|
-
return new DImagePiece(this, theme, this._textAlign, options);
|
|
30029
|
-
};
|
|
30030
30462
|
Object.defineProperty(DImageBase.prototype, "image", {
|
|
30031
30463
|
get: function () {
|
|
30032
|
-
|
|
30464
|
+
var _a;
|
|
30465
|
+
return ((_a = this._image) !== null && _a !== void 0 ? _a : (this._image = this.newImage()));
|
|
30033
30466
|
},
|
|
30034
30467
|
set: function (imageSource) {
|
|
30035
|
-
var image = this.
|
|
30036
|
-
image
|
|
30037
|
-
|
|
30468
|
+
var image = this.image.get(0);
|
|
30469
|
+
if (image != null) {
|
|
30470
|
+
image.source = imageSource;
|
|
30471
|
+
}
|
|
30038
30472
|
},
|
|
30039
30473
|
enumerable: false,
|
|
30040
30474
|
configurable: true
|
|
30041
30475
|
});
|
|
30476
|
+
DImageBase.prototype.getImage = function () {
|
|
30477
|
+
var _a;
|
|
30478
|
+
return ((_a = this._image) !== null && _a !== void 0 ? _a : (this._image = this.newImage()));
|
|
30479
|
+
};
|
|
30480
|
+
DImageBase.prototype.newImage = function () {
|
|
30481
|
+
return new DImagePieceContainerImpl(this, this.theme, this.options);
|
|
30482
|
+
};
|
|
30042
30483
|
DImageBase.prototype.onStateChange = function (newState, oldState) {
|
|
30043
30484
|
_super.prototype.onStateChange.call(this, newState, oldState);
|
|
30044
|
-
|
|
30045
|
-
for (var i = 0, imax = images.length; i < imax; ++i) {
|
|
30046
|
-
images[i].onStateChange(newState, oldState);
|
|
30047
|
-
}
|
|
30485
|
+
this.getImage().onStateChange(newState, oldState);
|
|
30048
30486
|
};
|
|
30049
30487
|
DImageBase.prototype.updateText = function () {
|
|
30050
30488
|
this.updateTextValue();
|
|
@@ -30052,15 +30490,8 @@
|
|
|
30052
30490
|
};
|
|
30053
30491
|
DImageBase.prototype.updateTextAndImage = function () {
|
|
30054
30492
|
var _a;
|
|
30055
|
-
var images = this._images;
|
|
30056
30493
|
var layouter = ((_a = DImageBase.LAYOUTER) !== null && _a !== void 0 ? _a : (DImageBase.LAYOUTER = new DImagePieceLayouter()));
|
|
30057
|
-
|
|
30058
|
-
var image = images[i];
|
|
30059
|
-
image.updateSource();
|
|
30060
|
-
image.updateTint();
|
|
30061
|
-
image.updateBound();
|
|
30062
|
-
layouter.add(image);
|
|
30063
|
-
}
|
|
30494
|
+
this.getImage().updateTextAndImage(layouter);
|
|
30064
30495
|
var text = this._text;
|
|
30065
30496
|
if (text != null) {
|
|
30066
30497
|
this.updateTextColor(text);
|
|
@@ -30077,11 +30508,8 @@
|
|
|
30077
30508
|
if (_super.prototype.isRefitable.call(this, target)) {
|
|
30078
30509
|
return true;
|
|
30079
30510
|
}
|
|
30080
|
-
|
|
30081
|
-
|
|
30082
|
-
if (images[i].isRefitable(target)) {
|
|
30083
|
-
return true;
|
|
30084
|
-
}
|
|
30511
|
+
if (this.getImage().isRefitable(target)) {
|
|
30512
|
+
return true;
|
|
30085
30513
|
}
|
|
30086
30514
|
return false;
|
|
30087
30515
|
};
|
|
@@ -30089,9 +30517,9 @@
|
|
|
30089
30517
|
return "DImageBase";
|
|
30090
30518
|
};
|
|
30091
30519
|
DImageBase.prototype.destroy = function () {
|
|
30092
|
-
var
|
|
30093
|
-
|
|
30094
|
-
|
|
30520
|
+
var image = this._image;
|
|
30521
|
+
if (image != null) {
|
|
30522
|
+
image.destroy();
|
|
30095
30523
|
}
|
|
30096
30524
|
_super.prototype.destroy.call(this);
|
|
30097
30525
|
};
|
|
@@ -47435,7 +47863,7 @@
|
|
|
47435
47863
|
var attrViewBox = "viewBox=\"0 0 ".concat(width * ratio, " ").concat(height * ratio, "\"");
|
|
47436
47864
|
var attrXmlns = "xmlns=\"http://www.w3.org/2000/svg\"";
|
|
47437
47865
|
var url = toSvgUrl("<svg ".concat(attrWidth, " ").concat(attrHeight, " ").concat(attrViewBox, " ").concat(attrXmlns, ">").concat(this._svg, "</svg>"));
|
|
47438
|
-
var scaleMode = (_c = options === null || options === void 0 ? void 0 : options.scaling) !== null && _c !== void 0 ? _c : pixi_js.SCALE_MODES.
|
|
47866
|
+
var scaleMode = (_c = options === null || options === void 0 ? void 0 : options.scaling) !== null && _c !== void 0 ? _c : pixi_js.SCALE_MODES.LINEAR;
|
|
47439
47867
|
var baseTexture = pixi_js.BaseTexture.from(url, {
|
|
47440
47868
|
resolution: resolution,
|
|
47441
47869
|
scaleMode: scaleMode
|
|
@@ -52569,35 +52997,13 @@
|
|
|
52569
52997
|
this.onColorChange();
|
|
52570
52998
|
this.emit("change", newValue, oldValue, this);
|
|
52571
52999
|
};
|
|
52572
|
-
DButtonColor.prototype.toImageTintOptions = function (tint) {
|
|
52573
|
-
var _this = this;
|
|
52574
|
-
var color = function () { return _this._textValueComputed.color; };
|
|
52575
|
-
if (tint) {
|
|
52576
|
-
return {
|
|
52577
|
-
color: tint.color || color,
|
|
52578
|
-
alpha: tint.alpha
|
|
52579
|
-
};
|
|
52580
|
-
}
|
|
52581
|
-
return {
|
|
52582
|
-
color: color
|
|
52583
|
-
};
|
|
52584
|
-
};
|
|
52585
|
-
DButtonColor.prototype.toImageOptions = function (theme, options) {
|
|
52586
|
-
if (options) {
|
|
52587
|
-
return {
|
|
52588
|
-
source: options.source,
|
|
52589
|
-
tint: this.toImageTintOptions(options.tint),
|
|
52590
|
-
align: options.align,
|
|
52591
|
-
margin: options.margin
|
|
52592
|
-
};
|
|
52593
|
-
}
|
|
52594
|
-
return {
|
|
52595
|
-
tint: this.toImageTintOptions()
|
|
52596
|
-
};
|
|
52597
|
-
};
|
|
52598
53000
|
DButtonColor.prototype.onColorChange = function () {
|
|
52599
|
-
|
|
52600
|
-
|
|
53001
|
+
var image = this.image.get(0);
|
|
53002
|
+
if (image != null) {
|
|
53003
|
+
var value = this._textValueComputed;
|
|
53004
|
+
if (value != null) {
|
|
53005
|
+
image.tint.color = value.color;
|
|
53006
|
+
}
|
|
52601
53007
|
}
|
|
52602
53008
|
this.updateTextForcibly();
|
|
52603
53009
|
};
|
|
@@ -65247,10 +65653,11 @@
|
|
|
65247
65653
|
var _this = _super.call(this, options) || this;
|
|
65248
65654
|
_this._isDone = true;
|
|
65249
65655
|
_this._startTime = 0;
|
|
65656
|
+
var theme = _this.theme;
|
|
65250
65657
|
var delay = options === null || options === void 0 ? void 0 : options.delay;
|
|
65251
|
-
_this._delayDone = (_a = delay === null || delay === void 0 ? void 0 : delay.done) !== null && _a !== void 0 ? _a :
|
|
65658
|
+
_this._delayDone = (_a = delay === null || delay === void 0 ? void 0 : delay.done) !== null && _a !== void 0 ? _a : theme.getDoneDelay();
|
|
65252
65659
|
var delayClose = delay === null || delay === void 0 ? void 0 : delay.close;
|
|
65253
|
-
_this._delayClose = delayClose !== undefined ? delayClose :
|
|
65660
|
+
_this._delayClose = delayClose !== undefined ? delayClose : theme.getCloseDelay();
|
|
65254
65661
|
_this._messageText = _this.message.text;
|
|
65255
65662
|
return _this;
|
|
65256
65663
|
}
|
|
@@ -65546,6 +65953,219 @@
|
|
|
65546
65953
|
return DExpandable;
|
|
65547
65954
|
}(DLayoutVertical));
|
|
65548
65955
|
|
|
65956
|
+
var STATE_INITIAL = 0;
|
|
65957
|
+
var STATE_STARTED = 1;
|
|
65958
|
+
var STATE_RESOLVED = 2;
|
|
65959
|
+
var STATE_REJECTED = 3;
|
|
65960
|
+
var DIndicatorProcessing = /** @class */ (function () {
|
|
65961
|
+
function DIndicatorProcessing(parent, options) {
|
|
65962
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
65963
|
+
this._parent = parent;
|
|
65964
|
+
this._state = STATE_INITIAL;
|
|
65965
|
+
this._startTime = 0;
|
|
65966
|
+
// Delay
|
|
65967
|
+
var theme = this.theme;
|
|
65968
|
+
var delay = options === null || options === void 0 ? void 0 : options.delay;
|
|
65969
|
+
this._delayDone = (_a = delay === null || delay === void 0 ? void 0 : delay.done) !== null && _a !== void 0 ? _a : theme.getProcessDoneDelay();
|
|
65970
|
+
var delayClose = delay === null || delay === void 0 ? void 0 : delay.close;
|
|
65971
|
+
this._delayClose = delayClose !== undefined ? delayClose : theme.getProcessCloseDelay();
|
|
65972
|
+
// Text
|
|
65973
|
+
var text = options === null || options === void 0 ? void 0 : options.text;
|
|
65974
|
+
this._isTextEnabled = (_b = text === null || text === void 0 ? void 0 : text.enabled) !== null && _b !== void 0 ? _b : theme.isProcessTextEnabled();
|
|
65975
|
+
this._textValue = (_c = text === null || text === void 0 ? void 0 : text.value) !== null && _c !== void 0 ? _c : theme.newProcessTextValue();
|
|
65976
|
+
// Image
|
|
65977
|
+
var image = options === null || options === void 0 ? void 0 : options.image;
|
|
65978
|
+
this._isImageEnabled = (_d = image === null || image === void 0 ? void 0 : image.enabled) !== null && _d !== void 0 ? _d : theme.isProcessImageEnabled();
|
|
65979
|
+
this._imageIndex = (_e = image === null || image === void 0 ? void 0 : image.index) !== null && _e !== void 0 ? _e : theme.getProcessImageIndex();
|
|
65980
|
+
this._imageSource = (_f = image === null || image === void 0 ? void 0 : image.source) !== null && _f !== void 0 ? _f : theme.newProcessImageSource();
|
|
65981
|
+
this._imageRotation = (_g = image === null || image === void 0 ? void 0 : image.rotation) !== null && _g !== void 0 ? _g : theme.newProcessImageRotation();
|
|
65982
|
+
// State
|
|
65983
|
+
this._wasReadOnly = false;
|
|
65984
|
+
}
|
|
65985
|
+
DIndicatorProcessing.prototype.start = function () {
|
|
65986
|
+
var state = this._state;
|
|
65987
|
+
if (state === STATE_INITIAL) {
|
|
65988
|
+
this._state = STATE_STARTED;
|
|
65989
|
+
this.onBegin();
|
|
65990
|
+
}
|
|
65991
|
+
else if (state === STATE_RESOLVED || state === STATE_REJECTED) {
|
|
65992
|
+
this._state = STATE_STARTED;
|
|
65993
|
+
this.onEnd();
|
|
65994
|
+
this.onBegin();
|
|
65995
|
+
}
|
|
65996
|
+
return this;
|
|
65997
|
+
};
|
|
65998
|
+
DIndicatorProcessing.prototype.onBegin = function () {
|
|
65999
|
+
this._startTime = Date.now();
|
|
66000
|
+
var timeoutId = this._timeoutId;
|
|
66001
|
+
if (timeoutId != null) {
|
|
66002
|
+
clearTimeout(timeoutId);
|
|
66003
|
+
}
|
|
66004
|
+
var closeTimeoutId = this._closeTimeoutId;
|
|
66005
|
+
if (closeTimeoutId != null) {
|
|
66006
|
+
clearTimeout(closeTimeoutId);
|
|
66007
|
+
}
|
|
66008
|
+
var parent = this._parent;
|
|
66009
|
+
var state = parent.state;
|
|
66010
|
+
state.lock();
|
|
66011
|
+
state.ticker.remove(DBaseState.PROCESSING).add(DBaseState.PROCESSING, 32);
|
|
66012
|
+
state.removeAll(DBaseState.SUCCEEDED, DBaseState.FAILED);
|
|
66013
|
+
this._wasReadOnly = state.isReadOnly;
|
|
66014
|
+
if (!this._wasReadOnly) {
|
|
66015
|
+
state.add(DBaseState.READ_ONLY);
|
|
66016
|
+
}
|
|
66017
|
+
state.unlock();
|
|
66018
|
+
if (this._isTextEnabled) {
|
|
66019
|
+
this._textValueBackup = parent.text;
|
|
66020
|
+
var textValue = this._textValue;
|
|
66021
|
+
if (textValue !== undefined) {
|
|
66022
|
+
parent.text = textValue;
|
|
66023
|
+
}
|
|
66024
|
+
}
|
|
66025
|
+
if (this._isImageEnabled) {
|
|
66026
|
+
var image = parent.image.get(this._imageIndex);
|
|
66027
|
+
if (image != null) {
|
|
66028
|
+
this._imageSourceBackup = image.source;
|
|
66029
|
+
this._imageRotationBackup = image.rotation;
|
|
66030
|
+
var imageSource = this._imageSource;
|
|
66031
|
+
if (imageSource !== undefined) {
|
|
66032
|
+
image.source = imageSource;
|
|
66033
|
+
}
|
|
66034
|
+
var imageRotation = this._imageRotation;
|
|
66035
|
+
if (imageRotation !== undefined) {
|
|
66036
|
+
image.rotation = imageRotation;
|
|
66037
|
+
}
|
|
66038
|
+
}
|
|
66039
|
+
}
|
|
66040
|
+
};
|
|
66041
|
+
DIndicatorProcessing.prototype.end = function () {
|
|
66042
|
+
var state = this._state;
|
|
66043
|
+
if (state === STATE_STARTED || state === STATE_RESOLVED || state === STATE_REJECTED) {
|
|
66044
|
+
this._state = STATE_INITIAL;
|
|
66045
|
+
this.onEnd();
|
|
66046
|
+
}
|
|
66047
|
+
return this;
|
|
66048
|
+
};
|
|
66049
|
+
DIndicatorProcessing.prototype.onEnd = function () {
|
|
66050
|
+
var timeoutId = this._timeoutId;
|
|
66051
|
+
if (timeoutId != null) {
|
|
66052
|
+
clearTimeout(timeoutId);
|
|
66053
|
+
}
|
|
66054
|
+
var closeTimeoutId = this._closeTimeoutId;
|
|
66055
|
+
if (closeTimeoutId != null) {
|
|
66056
|
+
clearTimeout(closeTimeoutId);
|
|
66057
|
+
}
|
|
66058
|
+
var parent = this._parent;
|
|
66059
|
+
var state = parent.state;
|
|
66060
|
+
state.lock();
|
|
66061
|
+
state.ticker.remove(DBaseState.PROCESSING);
|
|
66062
|
+
state.removeAll(DBaseState.SUCCEEDED, DBaseState.FAILED);
|
|
66063
|
+
if (!this._wasReadOnly) {
|
|
66064
|
+
state.remove(DBaseState.READ_ONLY);
|
|
66065
|
+
}
|
|
66066
|
+
state.unlock();
|
|
66067
|
+
if (this._isTextEnabled) {
|
|
66068
|
+
parent.text = this._textValueBackup;
|
|
66069
|
+
}
|
|
66070
|
+
if (this._isImageEnabled) {
|
|
66071
|
+
var image = parent.image.get(this._imageIndex);
|
|
66072
|
+
if (image != null) {
|
|
66073
|
+
image.source = this._imageSourceBackup;
|
|
66074
|
+
image.rotation = this._imageRotationBackup;
|
|
66075
|
+
}
|
|
66076
|
+
}
|
|
66077
|
+
};
|
|
66078
|
+
DIndicatorProcessing.prototype.resolve = function (message) {
|
|
66079
|
+
var _this = this;
|
|
66080
|
+
if (this._state === STATE_STARTED) {
|
|
66081
|
+
this._state = STATE_RESOLVED;
|
|
66082
|
+
var elapsedTime = Date.now() - this._startTime;
|
|
66083
|
+
var delay = this._delayDone - elapsedTime;
|
|
66084
|
+
if (0 < delay) {
|
|
66085
|
+
this._timeoutId = window.setTimeout(function () {
|
|
66086
|
+
_this._timeoutId = undefined;
|
|
66087
|
+
_this.onResolved(message);
|
|
66088
|
+
}, delay);
|
|
66089
|
+
}
|
|
66090
|
+
else {
|
|
66091
|
+
this.onResolved(message);
|
|
66092
|
+
}
|
|
66093
|
+
}
|
|
66094
|
+
};
|
|
66095
|
+
DIndicatorProcessing.prototype.onResolved = function (message) {
|
|
66096
|
+
var parent = this._parent;
|
|
66097
|
+
if (this._isTextEnabled && message != null) {
|
|
66098
|
+
parent.text = message;
|
|
66099
|
+
}
|
|
66100
|
+
var state = parent.state;
|
|
66101
|
+
state.lock();
|
|
66102
|
+
state.ticker.remove(DBaseState.PROCESSING);
|
|
66103
|
+
state.add(DBaseState.SUCCEEDED);
|
|
66104
|
+
state.remove(DBaseState.FAILED);
|
|
66105
|
+
if (!this._wasReadOnly) {
|
|
66106
|
+
state.remove(DBaseState.READ_ONLY);
|
|
66107
|
+
}
|
|
66108
|
+
state.unlock();
|
|
66109
|
+
this.onDone(this._delayClose);
|
|
66110
|
+
};
|
|
66111
|
+
DIndicatorProcessing.prototype.reject = function (message) {
|
|
66112
|
+
var _this = this;
|
|
66113
|
+
if (this._state === STATE_STARTED) {
|
|
66114
|
+
this._state = STATE_REJECTED;
|
|
66115
|
+
var elapsedTime = Date.now() - this._startTime;
|
|
66116
|
+
var delay = this._delayDone - elapsedTime;
|
|
66117
|
+
if (0 < delay) {
|
|
66118
|
+
this._timeoutId = window.setTimeout(function () {
|
|
66119
|
+
_this._timeoutId = undefined;
|
|
66120
|
+
_this.onRejected(message);
|
|
66121
|
+
}, delay);
|
|
66122
|
+
}
|
|
66123
|
+
else {
|
|
66124
|
+
this.onRejected(message);
|
|
66125
|
+
}
|
|
66126
|
+
}
|
|
66127
|
+
};
|
|
66128
|
+
DIndicatorProcessing.prototype.onRejected = function (message) {
|
|
66129
|
+
var parent = this._parent;
|
|
66130
|
+
if (this._isTextEnabled && message != null) {
|
|
66131
|
+
parent.text = message;
|
|
66132
|
+
}
|
|
66133
|
+
var state = parent.state;
|
|
66134
|
+
state.lock();
|
|
66135
|
+
state.ticker.remove(DBaseState.PROCESSING);
|
|
66136
|
+
state.add(DBaseState.FAILED);
|
|
66137
|
+
state.remove(DBaseState.SUCCEEDED);
|
|
66138
|
+
if (!this._wasReadOnly) {
|
|
66139
|
+
state.remove(DBaseState.READ_ONLY);
|
|
66140
|
+
}
|
|
66141
|
+
state.unlock();
|
|
66142
|
+
this.onDone(this._delayClose);
|
|
66143
|
+
};
|
|
66144
|
+
DIndicatorProcessing.prototype.onDone = function (delay) {
|
|
66145
|
+
var _this = this;
|
|
66146
|
+
if (delay != null) {
|
|
66147
|
+
this._closeTimeoutId = window.setTimeout(function () {
|
|
66148
|
+
_this._closeTimeoutId = undefined;
|
|
66149
|
+
_this.end();
|
|
66150
|
+
}, delay);
|
|
66151
|
+
}
|
|
66152
|
+
else {
|
|
66153
|
+
this.end();
|
|
66154
|
+
}
|
|
66155
|
+
};
|
|
66156
|
+
DIndicatorProcessing.prototype.getType = function () {
|
|
66157
|
+
return "DIndicatorProcessing";
|
|
66158
|
+
};
|
|
66159
|
+
Object.defineProperty(DIndicatorProcessing.prototype, "theme", {
|
|
66160
|
+
get: function () {
|
|
66161
|
+
return DThemes.get(this.getType());
|
|
66162
|
+
},
|
|
66163
|
+
enumerable: false,
|
|
66164
|
+
configurable: true
|
|
66165
|
+
});
|
|
66166
|
+
return DIndicatorProcessing;
|
|
66167
|
+
}());
|
|
66168
|
+
|
|
65549
66169
|
/*
|
|
65550
66170
|
* Copyright (C) 2019 Toshiba Corporation
|
|
65551
66171
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -73451,12 +74071,17 @@
|
|
|
73451
74071
|
DTableHeaderCell.prototype.isCheckClicked = function (e) {
|
|
73452
74072
|
if (e instanceof pixi_js.InteractionEvent && this._check.isEnabled) {
|
|
73453
74073
|
if (this.isSortable) {
|
|
73454
|
-
var image = this.
|
|
73455
|
-
if (image
|
|
74074
|
+
var image = this.image.get(1);
|
|
74075
|
+
if (image) {
|
|
73456
74076
|
var position = this.toClickPosition(e);
|
|
73457
|
-
var
|
|
73458
|
-
|
|
73459
|
-
|
|
74077
|
+
var object = image.object;
|
|
74078
|
+
if (object != null) {
|
|
74079
|
+
var bound = object.getLocalBounds();
|
|
74080
|
+
var margin = image.margin.horizontal;
|
|
74081
|
+
var x = object.x;
|
|
74082
|
+
return (x + bound.left - margin <= position &&
|
|
74083
|
+
position <= x + bound.right + margin);
|
|
74084
|
+
}
|
|
73460
74085
|
}
|
|
73461
74086
|
}
|
|
73462
74087
|
else {
|
|
@@ -76774,9 +77399,13 @@
|
|
|
76774
77399
|
DExpandable: DExpandable,
|
|
76775
77400
|
DHtmlElementState: DHtmlElementState,
|
|
76776
77401
|
DHtmlElement: DHtmlElement,
|
|
77402
|
+
DImageBaseThemeWrapperOther: DImageBaseThemeWrapperOther,
|
|
76777
77403
|
DImageBaseThemeWrapperSecondary: DImageBaseThemeWrapperSecondary,
|
|
76778
77404
|
DImageBaseThemeWrapperTertiary: DImageBaseThemeWrapperTertiary,
|
|
76779
77405
|
DImageBase: DImageBase,
|
|
77406
|
+
DImagePieceAlignImpl: DImagePieceAlignImpl,
|
|
77407
|
+
DImagePieceContainerImpl: DImagePieceContainerImpl,
|
|
77408
|
+
DImagePieceImpl: DImagePieceImpl,
|
|
76780
77409
|
DImagePieceLayouterPartBottom: DImagePieceLayouterPartBottom,
|
|
76781
77410
|
DImagePieceLayouterPartCenter: DImagePieceLayouterPartCenter,
|
|
76782
77411
|
DImagePieceLayouterPartContainer: DImagePieceLayouterPartContainer,
|
|
@@ -76786,8 +77415,10 @@
|
|
|
76786
77415
|
DImagePieceLayouterPartTop: DImagePieceLayouterPartTop,
|
|
76787
77416
|
DImagePieceLayouterPart: DImagePieceLayouterPart,
|
|
76788
77417
|
DImagePieceLayouter: DImagePieceLayouter,
|
|
76789
|
-
|
|
77418
|
+
DImagePieceMarginImpl: DImagePieceMarginImpl,
|
|
77419
|
+
DImagePieceTintImpl: DImagePieceTintImpl,
|
|
76790
77420
|
DImage: DImage,
|
|
77421
|
+
DIndicatorProcessing: DIndicatorProcessing,
|
|
76791
77422
|
DInputAndLabel: DInputAndLabel,
|
|
76792
77423
|
DInputBooleanButtonOff: DInputBooleanButtonOff,
|
|
76793
77424
|
DInputBooleanButtonOn: DInputBooleanButtonOn,
|