@magic-xpa/engine 4.1000.0-dev4100.3 → 4.1000.0-dev4100.32
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/esm2020/src/CurrentClientVersion.mjs +2 -2
- package/esm2020/src/commands/ClientToServer/CommandFactory.mjs +10 -2
- package/esm2020/src/exp/ExpressionEvaluator.mjs +23 -1
- package/fesm2015/magic-xpa-engine.mjs +42 -8
- package/fesm2015/magic-xpa-engine.mjs.map +1 -1
- package/fesm2020/magic-xpa-engine.mjs +37 -8
- package/fesm2020/magic-xpa-engine.mjs.map +1 -1
- package/package.json +4 -4
- package/src/commands/ClientToServer/CommandFactory.d.ts +3 -0
- package/src/exp/ExpressionEvaluator.d.ts +1 -0
@@ -8095,6 +8095,13 @@ class SelectProgramCommand extends ExecOperCommand {
|
|
8095
8095
|
}
|
8096
8096
|
}
|
8097
8097
|
|
8098
|
+
class ControlItemsRefreshCommand extends DataviewCommand {
|
8099
|
+
constructor() {
|
8100
|
+
super();
|
8101
|
+
this.Control = null;
|
8102
|
+
}
|
8103
|
+
}
|
8104
|
+
|
8098
8105
|
class CommandFactory {
|
8099
8106
|
static CreateEventCommand(taskTag, magicEvent) {
|
8100
8107
|
let eventCommand = new EventCommand(magicEvent);
|
@@ -8113,6 +8120,13 @@ class CommandFactory {
|
|
8113
8120
|
dataviewCommand.TaskTag = taskId;
|
8114
8121
|
return dataviewCommand;
|
8115
8122
|
}
|
8123
|
+
static CreateControlItemsRefreshCommand(taskId, control) {
|
8124
|
+
let command = new ControlItemsRefreshCommand();
|
8125
|
+
command.CommandType = DataViewCommandType.ControlItemsRefresh;
|
8126
|
+
command.TaskTag = taskId;
|
8127
|
+
command.Control = control;
|
8128
|
+
return command;
|
8129
|
+
}
|
8116
8130
|
static CreateAddUserRangeDataviewCommand(taskId, userRange) {
|
8117
8131
|
let addUserRangeDataviewCommand = new AddUserRangeDataviewCommand();
|
8118
8132
|
addUserRangeDataviewCommand.TaskTag = taskId;
|
@@ -11090,6 +11104,11 @@ class ExpressionEvaluator extends GuiExpressionEvaluator {
|
|
11090
11104
|
this.eval_op_VarDisplayName(resVal, val1);
|
11091
11105
|
expStrTracker.resetNullResult();
|
11092
11106
|
break;
|
11107
|
+
case ExpressionInterface.EXP_OP_CONTROL_ITEMS_REFRESH:
|
11108
|
+
val2 = valStack.pop();
|
11109
|
+
val1 = valStack.pop();
|
11110
|
+
this.eval_op_controlItemRefresh(val1, val2, resVal);
|
11111
|
+
break;
|
11093
11112
|
case ExpressionInterface.EXP_OP_VARCONTROLID:
|
11094
11113
|
val1 = valStack.pop();
|
11095
11114
|
this.eval_op_VarControlID(resVal, val1);
|
@@ -13234,6 +13253,28 @@ class ExpressionEvaluator extends GuiExpressionEvaluator {
|
|
13234
13253
|
resVal.StrVal = fld.VarDisplayName;
|
13235
13254
|
}
|
13236
13255
|
}
|
13256
|
+
eval_op_controlItemRefresh(val1, val2, resVal) {
|
13257
|
+
const _super = Object.create(null, {
|
13258
|
+
GetContextTask: { get: () => super.GetContextTask }
|
13259
|
+
});
|
13260
|
+
return __awaiter(this, void 0, void 0, function* () {
|
13261
|
+
let success = false;
|
13262
|
+
let parent = val2.MgNumVal.NUM_2_LONG();
|
13263
|
+
resVal.Attr = StorageAttribute.BOOLEAN;
|
13264
|
+
if ((parent >= 0 && parent < (this.ExpTask.getTaskDepth(false))) || parent === ExpressionEvaluator.TRIGGER_TASK) {
|
13265
|
+
let tsk = _super.GetContextTask.call(this, parent);
|
13266
|
+
if (tsk != null) {
|
13267
|
+
let control = tsk.getForm().GetCtrl(val1.StrVal);
|
13268
|
+
if (control != null && control.isChoiceControl() && control.isDataCtrl()) {
|
13269
|
+
let command = CommandFactory.CreateControlItemsRefreshCommand(tsk.getTaskTag(), control);
|
13270
|
+
yield tsk.DataviewManager.CurrentDataviewManager.Execute(command);
|
13271
|
+
success = true;
|
13272
|
+
}
|
13273
|
+
}
|
13274
|
+
}
|
13275
|
+
resVal.BoolVal = success;
|
13276
|
+
});
|
13277
|
+
}
|
13237
13278
|
eval_op_VarControlID(resVal, val1) {
|
13238
13279
|
let ret = 0;
|
13239
13280
|
if (val1.MgNumVal !== null) {
|
@@ -30387,7 +30428,7 @@ class CommandsTable {
|
|
30387
30428
|
}
|
30388
30429
|
}
|
30389
30430
|
|
30390
|
-
let CurrentClientVersion = '4.1000.0-dev4100.
|
30431
|
+
let CurrentClientVersion = '4.1000.0-dev4100.32';
|
30391
30432
|
|
30392
30433
|
class ClientManager {
|
30393
30434
|
constructor() {
|
@@ -30828,13 +30869,6 @@ class MagicBridge {
|
|
30828
30869
|
}
|
30829
30870
|
}
|
30830
30871
|
|
30831
|
-
class ControlItemsRefreshCommand extends DataviewCommand {
|
30832
|
-
constructor() {
|
30833
|
-
super();
|
30834
|
-
this.Control = null;
|
30835
|
-
}
|
30836
|
-
}
|
30837
|
-
|
30838
30872
|
class DataViewOutputCommand extends DataviewCommand {
|
30839
30873
|
constructor(OutputCommandType) {
|
30840
30874
|
super();
|