@magic-xpa/gui 4.1100.0-dev4110.261 → 4.1100.0-dev4110.267
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/esm2022/src/Commands.mjs +3 -3
- package/esm2022/src/GuiEnums.mjs +2 -1
- package/esm2022/src/Manager.mjs +2 -2
- package/esm2022/src/gui/low/GuiInteractive.mjs +3 -2
- package/esm2022/src/management/gui/MgControlBase.mjs +12 -2
- package/fesm2022/magic-xpa-gui.mjs +17 -5
- package/fesm2022/magic-xpa-gui.mjs.map +1 -1
- package/package.json +2 -2
- package/src/Commands.d.ts +1 -1
- package/src/GuiEnums.d.ts +2 -1
- package/src/gui/low/GuiInteractive.d.ts +1 -1
- package/src/management/gui/MgControlBase.d.ts +2 -0
|
@@ -555,9 +555,10 @@ class GuiInteractiveBase {
|
|
|
555
555
|
this._boolVal = retSuggestedValue;
|
|
556
556
|
this.Invoke();
|
|
557
557
|
}
|
|
558
|
-
getValue(obj, line) {
|
|
558
|
+
getValue(obj, line, isThreeStateCheckBox) {
|
|
559
559
|
this._commandType = InteractiveCommandType.GET_VALUE;
|
|
560
560
|
this._obj2 = obj;
|
|
561
|
+
this._boolVal = isThreeStateCheckBox;
|
|
561
562
|
this._line = line;
|
|
562
563
|
this._mgValue = new MgValue();
|
|
563
564
|
this.Invoke();
|
|
@@ -1055,6 +1056,7 @@ var HtmlProperties;
|
|
|
1055
1056
|
HtmlProperties["SelectedLayer"] = "SelectedLayer";
|
|
1056
1057
|
HtmlProperties["BindingLevel"] = "bindingLevel";
|
|
1057
1058
|
HtmlProperties["ZoomButtonTooltip"] = "ZoomButtonTooltip";
|
|
1059
|
+
HtmlProperties["CheckBoxIndeterminate"] = "CheckBoxIndeterminate";
|
|
1058
1060
|
})(HtmlProperties || (HtmlProperties = {}));
|
|
1059
1061
|
var MenuStyle;
|
|
1060
1062
|
(function (MenuStyle) {
|
|
@@ -1204,9 +1206,9 @@ class Commands {
|
|
|
1204
1206
|
let guiInteractive = new GuiInteractive();
|
|
1205
1207
|
guiInteractive.setGetSuggestedValueOfChoiceControlOnTagData(ctrl, line, retSuggestedValue);
|
|
1206
1208
|
}
|
|
1207
|
-
static getValue(obj, line) {
|
|
1209
|
+
static getValue(obj, line, isThreeStateCheckBox) {
|
|
1208
1210
|
let guiInteractive = new GuiInteractive();
|
|
1209
|
-
return guiInteractive.getValue(obj, line);
|
|
1211
|
+
return guiInteractive.getValue(obj, line, isThreeStateCheckBox);
|
|
1210
1212
|
}
|
|
1211
1213
|
static getTopIndex(tablecontrol) {
|
|
1212
1214
|
let guiInteractive = new GuiInteractive();
|
|
@@ -1629,7 +1631,7 @@ class Manager {
|
|
|
1629
1631
|
}
|
|
1630
1632
|
}
|
|
1631
1633
|
static GetCtrlVal(ctrl) {
|
|
1632
|
-
return Commands.getValue(ctrl, ctrl.getDisplayLine(true));
|
|
1634
|
+
return Commands.getValue(ctrl, ctrl.getDisplayLine(true), ctrl.isThreeStateCheckBox());
|
|
1633
1635
|
}
|
|
1634
1636
|
static async SetReadOnlyControl(ctrl, isReadOnly) {
|
|
1635
1637
|
if (ctrl.isTextControl() || ctrl.IsRepeatable || ctrl.isComboBox() || ctrl.isListBox() || ctrl.isCheckBox() || ctrl.isRadio()) {
|
|
@@ -12428,6 +12430,16 @@ class MgControlBase extends GuiControlPropertyAdapter {
|
|
|
12428
12430
|
setCheckBoxValue(line, mgVal) {
|
|
12429
12431
|
let checkState = DisplayConvertor.toBoolean(mgVal);
|
|
12430
12432
|
Commands.addValueWithLine(CommandType.SET_VALUE, this, line, checkState);
|
|
12433
|
+
Commands.addOperationWithLine(CommandType.SET_PROPERTY, this, this.getDisplayLine(false), HtmlProperties.CheckBoxIndeterminate, this.IsNull);
|
|
12434
|
+
}
|
|
12435
|
+
setAsThreeState() {
|
|
12436
|
+
this._propTab.setProp(PropInterface.PROP_TYPE_THREE_STATES, "1", this, "C");
|
|
12437
|
+
}
|
|
12438
|
+
isThreeStateCheckBox() {
|
|
12439
|
+
let isThreeStateCheckBox = false;
|
|
12440
|
+
if (this.isCheckBox())
|
|
12441
|
+
isThreeStateCheckBox = this.GetComputedBooleanProperty(PropInterface.PROP_TYPE_THREE_STATES, false);
|
|
12442
|
+
return isThreeStateCheckBox;
|
|
12431
12443
|
}
|
|
12432
12444
|
async refreshAndSetItemListByDataSource(line, valueChanged) {
|
|
12433
12445
|
if (this.SupportsDataSource()) {
|
|
@@ -12912,7 +12924,7 @@ class MgControlBase extends GuiControlPropertyAdapter {
|
|
|
12912
12924
|
return retIsNullControl;
|
|
12913
12925
|
}
|
|
12914
12926
|
CanGetNullFromControlValue() {
|
|
12915
|
-
return
|
|
12927
|
+
return this.isThreeStateCheckBox() && (this._field == null || this._field.NullAllowed);
|
|
12916
12928
|
}
|
|
12917
12929
|
isChoiceNull(idx) {
|
|
12918
12930
|
let result;
|