@magic-xpa/engine 4.1100.0-dev4110.207 → 4.1100.0-dev4110.212
Sign up to get free protection for your applications and to get access to all the features.
- package/esm2022/src/ClientManager.mjs +5 -5
- package/esm2022/src/CurrentClientVersion.mjs +2 -2
- package/esm2022/src/gui/MgForm.mjs +45 -2
- package/esm2022/src/tasks/Task.mjs +4 -3
- package/fesm2022/magic-xpa-engine.mjs +50 -7
- package/fesm2022/magic-xpa-engine.mjs.map +1 -1
- package/package.json +4 -4
- package/src/ClientManager.d.ts +1 -0
- package/src/gui/MgForm.d.ts +3 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
import { Commands, CommandType, DataModificationTypes, GuiEnvironment, Manager, MgFormBase, PropInterface } from '@magic-xpa/gui';
|
2
2
|
import { Constants, InternalInterface, Logger, MgControlType, Misc, Priority, XMLConstants } from '@magic-xpa/utils';
|
3
|
-
import { ApplicationException, Debug, Exception, Int32, NString, RefParam, StringBuilder } from '@magic-xpa/mscorelib';
|
3
|
+
import { ApplicationException, Debug, Exception, Int32, isNullOrUndefined, NString, RefParam, StringBuilder } from '@magic-xpa/mscorelib';
|
4
4
|
import { MgControl } from './MgControl';
|
5
5
|
import { RecordOutOfDataViewException } from '../data/RecordOutOfDataViewException';
|
6
6
|
import { SET_DISPLAYLINE_BY_DV } from '../data/DataView';
|
@@ -10,6 +10,7 @@ import { ConstInterface } from '../ConstInterface';
|
|
10
10
|
import { LastFocusedManager } from '../rt/LastFocusedManager';
|
11
11
|
import { CreatedFormVector } from './CreatedFormVector';
|
12
12
|
import { AccessHelper } from '../AccessHelper';
|
13
|
+
import { ClientManager } from '../ClientManager';
|
13
14
|
export class MgForm extends MgFormBase {
|
14
15
|
static TIME_LIMIT = 50;
|
15
16
|
IsMovingInView = false;
|
@@ -1177,5 +1178,47 @@ export class MgForm extends MgFormBase {
|
|
1177
1178
|
getDvRowIdx(guiRowIdx) {
|
1178
1179
|
return guiRowIdx - this.GetDataview().RecordsBeforeCurrentView;
|
1179
1180
|
}
|
1181
|
+
async moveToFirstParkabelControl(callByDestSubForm) {
|
1182
|
+
let task = this.getTask();
|
1183
|
+
let parkableCtrl = null;
|
1184
|
+
parkableCtrl = await this.getValidParkableControl();
|
1185
|
+
ClientManager.handlingFirstParkableControl = true;
|
1186
|
+
if (!isNullOrUndefined(parkableCtrl))
|
1187
|
+
await parkableCtrl.invoke();
|
1188
|
+
else if (!callByDestSubForm)
|
1189
|
+
await AccessHelper.eventsManager.HandleNonParkableControls(task);
|
1190
|
+
ClientManager.handlingFirstParkableControl = false;
|
1191
|
+
}
|
1192
|
+
async getValidParkableControl() {
|
1193
|
+
let ctrlName = await this.getFirstParkableControlName();
|
1194
|
+
let ctrl = await this.GetCtrl(ctrlName);
|
1195
|
+
if (!isNullOrUndefined(ctrl)) {
|
1196
|
+
switch (ctrl.Type) {
|
1197
|
+
case MgControlType.CTRL_TYPE_BUTTON:
|
1198
|
+
case MgControlType.CTRL_TYPE_CHECKBOX:
|
1199
|
+
case MgControlType.CTRL_TYPE_RADIO:
|
1200
|
+
case MgControlType.CTRL_TYPE_COMBO:
|
1201
|
+
case MgControlType.CTRL_TYPE_LIST:
|
1202
|
+
case MgControlType.CTRL_TYPE_TEXT:
|
1203
|
+
if (!ctrl.isParkable(true))
|
1204
|
+
ctrl = null;
|
1205
|
+
break;
|
1206
|
+
default:
|
1207
|
+
ctrl = null;
|
1208
|
+
break;
|
1209
|
+
}
|
1210
|
+
}
|
1211
|
+
return ctrl;
|
1212
|
+
}
|
1213
|
+
async getFirstParkableControlName() {
|
1214
|
+
let ctrlName = '';
|
1215
|
+
if (this.checkIfExistProp(PropInterface.PROP_TYPE_PARK_FIRST_ON)) {
|
1216
|
+
if (this.getProp(PropInterface.PROP_TYPE_PARK_FIRST_ON).isExpression())
|
1217
|
+
ctrlName = await this.getProp(PropInterface.PROP_TYPE_PARK_FIRST_ON).getValue();
|
1218
|
+
else
|
1219
|
+
ctrlName = this.getProp(PropInterface.PROP_TYPE_PARK_FIRST_ON).getOrgValue();
|
1220
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ElPTl9QUkVWIHx8XHJcbiAgICAgICAgZGlyZWN0aW9uID09PSBDb25zdGFudHMuTU9WRV9ESVJFQ1RJT05fQkVHSU5cclxuICAgICAgICAgID8gLXNpemVcclxuICAgICAgICAgIDogc2l6ZSk7XHJcblxyXG4gICAgICAgIGlmICh0aGlzLmlzTGluZU1vZGUoKSkge1xyXG4gICAgICAgICAgdmlzaWJsZUxpbmUgPSB0aGlzLmdldFZpc2libGVMaW5lKCk7XHJcbiAgICAgICAgICBpZiAodmlzaWJsZUxpbmUgPCAwKSB7XHJcbiAgICAgICAgICAgIHZpc2libGVMaW5lID0gMDtcclxuICAgICAgICAgICAgcmVjb3JkT3V0T2ZWaWV3ID0gdHJ1ZTtcclxuICAgICAgICAgIH1cclxuICAgICAgICAgIGlmICh2aXNpYmxlTGluZSA+IHRoaXMuX3Jvd3NJblBhZ2UgKyAxKSB7XHJcbiAgICAgICAgICAgIHZpc2libGVMaW5lID0gdGhpcy5fcm93c0luUGFnZTtcclxuICAgICAgICAgICAgcmVjb3JkT3V0T2ZWaWV3ID0gdHJ1ZTtcclxuICAgICAgICAgIH1cclxuICAgICAgICAgIC8vIHNjcm9sbGluZyB0aGUgdGFibGUgb25lIHBhZ2Ugb3Igb25lIHJvdyB1cCBvciBkb3duXHJcbiAgICAgICAgICBpZiAodW5pdCA9PT0gQ29uc3RhbnRzLk1PVkVfVU5JVF9QQUdFICYmXHJcbiAgICAgICAgICAgIChkaXJlY3Rpb24gPT09IENvbnN0YW50cy5NT1ZFX0RJUkVDVElPTl9ORVhUIHx8XHJcbiAgICAgICAgICAgICAgZGlyZWN0aW9uID09PSBDb25zdGFudHMuTU9WRV9ESVJFQ1RJT05fUFJFVikgfHxcclxuICAgICAgICAgICAgdW5pdCA9PT0gQ29uc3RhbnRzLk1PVkVfVU5JVF9ST1cgJiZcclxuICAgICAgICAgICAgKGRpcmVjdGlvbiA9PT0gQ29uc3RhbnRzLk1PVkVfRElSRUNUSU9OX05FWFQgJiYgdmlzaW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ld0V4Y2VwdGlvbikge1xyXG4gICAgICAgICAgICAgICAgKDxEYXRhVmlldz50aGlzLkdldERhdGF2aWV3KCkpLnNldFRvcFJlY0lkeE1vZGlmaWVkKGZhbHNlKTtcclxuICAgICAgICAgICAgICAgIGlmIChBY2Nlc3NIZWxwZXIuZXZlbnRzTWFuYWdlci5HZXRTdG9wRXhlY3V0aW9uRmxhZygpKSB7XHJcbiAgICAgICAgICAgICAgICAgICg8RGF0YVZpZXc+dGhpcy5HZXREYXRhdmlldygpKS5yZXN0b3JlVG9wUmVjSWR4KCk7XHJcbiAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMucmVzdG9yZU9sZERpc3BsYXlMaW5lKG9sZERpc3BsYXlMaW5lKTtcclxuICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgaWYgKHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRUb3BSZWNJZHgoKSA8IDApIHtcclxuICAgICAgICAgICAgICAgICAgdGhpcy5HZXREYXRhdmlldygpLnNldFRvcFJlY0lkeCgwKTtcclxuICAgICAgICAgICAgICAgICAgdHJ5IHtcclxuICAgICAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLnNldEN1cnJSb3dCeURpc3BsYXlMaW5lKDAsIHRydWUsIGZhbHNlKTtcclxuICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICBjYXRjaCAoZXhjZXB0aW9uKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKGV4Y2VwdGlvbiBpbnN0YW5jZW9mIEV4Y2VwdGlvbikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgLy8gUUNSICM5OTU0OTY6IHdoZW4gdGhlIHJlY29yZCBzdWZmaXggZmFpbGVkIGdvIGJhY2sgdG8gdGhlXHJcbiAgICAgICAgICAgICAgICAgICAgICAvLyBvcmlnaW5hbCByb3dcclxuICAgICAgICAgICAgICAgICAgICAgIGlmIChBY2Nlc3NIZWxwZXIuZXZlbnRzTWFuYWdlci5HZXRTdG9wRXhlY3V0aW9uRmxhZygpKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICg8RGF0YVZpZXc+dGhpcy5HZXREYXRhdmlldygpKS5yZXN0b3JlVG9wUmVjSWR4KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMucmVzdG9yZU9sZERpc3BsYXlMaW5lKG9sZERpc3BsYXlMaW5lKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLlJlZnJlc2hEaXNwbGF5KENvbnN0YW50cy5UQVNLX1JFRlJFU0hfRk9STSk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBlbHNlIGlmICh1bml0ICE9PSBDb25zdGFudHMuTU9WRV9VTklUX1JPVyAmJiAoPERhdGFWaWV3PnRoaXMuR2V0RGF0YXZpZXcoKSkucmVjRXhpc3RzKHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRUb3BSZWNJZHgoKSkpIHtcclxuICAgICAgICAgICAgICAgICAgLy8gUUNSICM5OTIxMDE6IGlmIHdlIHJlYWNoZWQgdGhpcyBwb2ludCBpdCBtZWFucyB0aGF0IHRoZSByZWMgc3VmZml4XHJcbiAgICAgICAgICAgICAgICAgIC8vIHdhc24ndCBleGVjdXRlZCBzbyB3ZSBtdXN0IGhhbmRsZSBpdCBiZWZvcmUgd2UgZ28gdG8gYSBuZXcgcm93XHJcbiAgICAgICAgICAgICAgICAgIGxldCBuZXdSZWNJZDogbnVtYmVyID0gKHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRDdXJyUmVjKCkpLmdldElkKCk7XHJcbiAgICAgICAgICAgICAgICAgIGlmIChuZXdSZWNJZCA9PT0gb2xkUmVjSWQgJiYgIXRoaXMuX3N1ZmZpeERvbmUpXHJcbiAgICAgICAgICAgICAgICAgICAgLy8gUUNSIDc1ODYzOVxyXG4gICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgYXdhaXQgQWNjZXNzSGVscGVyLmV2ZW50c01hbmFnZXIuaGFuZGxlSW50ZXJuYWxFdmVudFdpdGhUYXNrKHRoaXMuX3Rhc2ssIEludGVybmFsSW50ZXJmYWNlLk1HX0FDVF9SRUNfU1VGRklYKTtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoQWNjZXNzSGVscGVyLmV2ZW50c01hbmFnZXIuR2V0U3RvcEV4ZWN1dGlvbkZsYWcoKSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgKDxEYXRhVmlldz50aGlzLkdldERhdGF2aWV3KCkpLnJlc3RvcmVUb3BSZWNJZHgoKTtcclxuICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMucmVzdG9yZU9sZERpc3BsYXlMaW5lKG9sZERpc3BsYXlMaW5lKTtcclxuICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgdHJ5IHtcclxuICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuUmVmcmVzaERpc3BsYXkoQ29uc3RhbnRzLlRBU0tfUkVGUkVTSF9GT1JNKTtcclxuICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2V0Q3VyclJvd0J5RGlzcGxheUxpbmUodGhpcy5HZXREYXRhdmlldygpLmdldFRvcFJlY0lkeCgpICsgdGhpcy5nZXRMYXN0VmFsaWRSb3coKSwgZmFsc2UsIHRydWUpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgdmlzaWJsZUxpbmUgPSB0aGlzLmdldExhc3RWYWxpZFJvdygpO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICBjYXRjaCAoRXhjZXB0aW9uKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgKDxEYXRhVmlldz50aGlzLkdldERhdGF2aWV3KCkpLnJlc3RvcmVUb3BSZWNJZHgoKTtcclxuICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5yZXN0b3JlT2xkRGlzcGxheUxpbmUob2xkRGlzcGxheUxpbmUpO1xyXG4gICAgICAgICAgICAgICAgICBpZiAodW5pdCA9PT0gQ29uc3RhbnRzLk1PVkVfVU5JVF9ST1cgJiYgZGlyZWN0aW9uID09PSBDb25zdGFudHMuTU9WRV9ESVJFQ1RJT05fTkVYVCkge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIG5vbiBpbnRlcmFjdGl2ZSwgZW5kIG9mIGRhdGEgbWVhbnMgZW5kIG9mIG93bmVyVGFzaywgdW5sZXNzIHdlIGFyZSBpbiBjcmVhdGUgbW9kZS5cclxuICAgICAgICAgICAgICAgICAgICBpZiAoIXRoaXMuX3Rhc2suSXNJbnRlcmFjdGl2ZSAmJiB0aGlzLl90YXNrLmdldE1vZGUoKSAhPT0gQ29uc3RhbnRzLlRBU0tfTU9ERV9DUkVBVEUpXHJcbiAgICAgICAgICAgICAgICAgICAgICAoPFRhc2tCYXNlPnRoaXMuX3Rhc2spLnNldEV4ZWNFbmRUYXNrKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgZWxzZVxyXG4gICAgICAgICAgICAgICAgICAgICAgYXdhaXQgQWNjZXNzSGVscGVyLmV2ZW50c01hbmFnZXIuaGFuZGxlSW50ZXJuYWxFdmVudFdpdGhUYXNrKHRoaXMuX3Rhc2ssIEludGVybmFsSW50ZXJmYWNlLk1HX0FDVF9DUkVMSU5FKTtcclxuICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBMb2dnZXIuSW5zdGFuY2UuV3JpdGVEZXZUb0xvZyhleC5NZXNzYWdlKTtcclxuICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgIH1cclxuICAgICAgICAgIC8vIG1vdmluZyB0aGUgbWFya2luZyBvbmUgcm93IHVwIG9yIGRvd25cclxuICAgICAgICAgIGVsc2Uge1xyXG4gICAgICAgICAgICB0cnkge1xyXG4gICAgICAgICAgICAgIG9sZFRhc2tNb2RlID0gdGhpcy5fdGFzay5nZXRNb2RlKCk7XHJcblxyXG4gICAgICAgICAgICAgIG9sZFJlY0lkID0gKHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRDdXJyUmVjKCkpLmdldElkKCk7XHJcbiAgICAgICAgICAgICAgYXdhaXQgdGhpcy5zZXRDdXJyUm93QnlEaXNwbGF5TGluZShvbGREaXNwbGF5TGluZSArIHNpemUsIHRydWUsIGZhbHNlKTtcclxuXHJcbiAgICAgICAgICAgICAgLy8gaWYgdGhlIHJlY29yZCB3YXMgZGVsZXRlZCBpbiBSdW4gVGltZSBieSBGb3JjZSBEZWxldGUgZm9yIGV4YW1wbGVcclxuICAgICAgICAgICAgICBpZiAoISg8RGF0YVZpZXc+dGhpcy5HZXREYXRhdmlldygpKS5yZWNFeGlzdHNCeUlkKG9sZFJlY0lkKSkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHNpemUgPiAwIHx8IG9sZFRhc2tNb2RlICE9PSBDb25zdGFudHMuVEFTS19NT0RFX0NSRUFURSlcclxuICAgICAgICAgICAgICAgICAgaWYgKHNpemUgIT09IC0xIHx8ICg8RGF0YVZpZXc+dGhpcy5HZXREYXRhdmlldygpKS5yZWNFeGlzdHMob2xkRGlzcGxheUxpbmUpKVxyXG4gICAgICAgICAgICAgICAgICAgIC8vIFFDUiAjMjkzNjY4XHJcbiAgICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5zZXRDdXJyUm93QnlEaXNwbGF5TGluZShvbGREaXNwbGF5TGluZSwgZmFsc2UsIGZhbHNlKTtcclxuICAgICAgICAgICAgICAgICAgZWxzZVxyXG4gICAgICAgICAgICAgICAgICAgIExvZ2dlci5JbnN0YW5jZS5Xcml0ZURldlRvTG9nKE5TdHJpbmcuRm9ybWF0KFwic2tpcHBlZCBzZXRjdXJyUm93IGZvciByb3cgezB9XCIsIG9sZERpc3BsYXlMaW5lKSk7XHJcbiAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLlJlZnJlc2hEaXNwbGF5KENvbnN0YW50cy5UQVNLX1JFRlJFU0hfRk9STSk7XHJcbiAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgIGVsc2UgaWYgKEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLkdldFN0b3BFeGVjdXRpb25GbGFnKCkpIHtcclxuICAgICAgICAgICAgICAgIC8vIHBlcmZvcm1hbmNlIGltcHJvdmVtZW50OiBpZiBldmVyeXRoaW5nIGlzIE9LLCBjdXJyIHJlYyB3aWxsIGxhdGVyIGJlIHJlZnJlc2hlZCBpblxyXG4gICAgICAgICAgICAgICAgLy8gUkVDX1BSRUZJWFxyXG4gICAgICAgICAgICAgICAgLy8gdGh1cywgcmVmcmVzaCBvbmx5IGluIGNhc2Ugb2YgZXJyb3IuXHJcbiAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLlJlZnJlc2hEaXNwbGF5KENvbnN0YW50cy5UQVNLX1JFRlJFU0hfQ1VSUl9SRUMpO1xyXG4gICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBjYXRjaCAoZXgpIHtcclxuICAgICAgICAgICAgICBpZiAoZXggaW5zdGFuY2VvZiBSZWNvcmRPdXRPZkRhdGFWaWV3RXhjZXB0aW9uKSB7XHJcbiAgICAgICAgICAgICAgICAvLyBTb21ldG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AgICAgICAgICAgICBhd2FpdCBBY2Nlc3NIZWxwZXIuZXZlbnRzTWFuYWdlci5oYW5kbGVJbnRlcm5hbEV2ZW50V2l0aFRhc2sodGhpcy5fdGFzaywgSW50ZXJuYWxJbnRlcmZhY2UuTUdfQUNUX0NSRUxJTkUpO1xyXG4gICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICBlbHNlXHJcbiAgICAgICAgICAgICAgICBMb2dnZXIuSW5zdGFuY2UuV3JpdGVEZXZUb0xvZyhleC5NZXNzYWdlKTtcclxuICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgZWxzZSBpZiAoZXggaW5zdGFuY2VvZiBTZXJ2ZXJFcnJvcikge1xyXG4gICAgICAgICAgICAgIGF3YWl0ICg8VGFza0Jhc2U+dGhpcy5fdGFzaykuc3RvcCgpO1xyXG4gICAgICAgICAgICAgICg8VGFza0Jhc2U+dGhpcy5fdGFzaykuYWJvcnQoKTtcclxuICAgICAgICAgICAgICBhd2FpdCBBY2Nlc3NIZWxwZXIuZXZlbnRzTWFuYWdlci5Qcm9jZXNzQWJvcnRpbmdFcnJvcihleCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgZWxzZSBpZiAoZXggaW5zdGFuY2VvZiBFeGNlcHRpb24pIHtcclxuICAgICAgICAgICAgICBMb2dnZXIuSW5zdGFuY2UuV3JpdGVEZXZUb0xvZyhleC5NZXNzYWdlKTtcclxuICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICAgIH1cclxuICAgICAgaWYgKHJldHVyblRvVmlzaWJsZUxpbmUpIHtcclxuICAgICAgICBpZiAocmVjb3JkT3V0T2ZWaWV3KSB7XHJcbiAgICAgICAgICBpZiAodmlzaWJsZUxpbmUgPT09IDApXHJcbiAgICAgICAgICAgIHRoaXMuR2V0RGF0YXZpZXcoKS5zZXRUb3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XG4gICAgLy8gdGhlIGVtcHRpbmVzcyBvZiB0aGUgRFYgbXVzdCBiZSBjaGVja2VkIGFnYWluIGJlY2F1c2UgdGhlIFwiY3JlYXRlIGxpbmVcIiBtYXkgZmFpbFxyXG4gICAgaWYgKCF0aGlzLkdldERhdGF2aWV3KCkuaXNFbXB0eSgpKSB7XHJcbiAgICAgIGlmIChzdXBlci5pc0xpbmVNb2RlKCkpIHtcclxuICAgICAgICB0cnkge1xyXG4gICAgICAgICAgaWYgKHN1cGVyLkhhc1RhYmxlKCkpIHtcclxuICAgICAgICAgICAgcm93ID0gdGhpcy5nZXRWaXNpYmxlTGluZSgpO1xyXG4gICAgICAgICAgICBpZiAocm93IDwgMCB8fCByb3cgPj0gdGhpcy5fcm93c0luUGFnZSkge1xyXG4gICAgICAgICAgICAgIGxldCB0b3BSZWNJZHg6IG51bWJlciA9IHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRUb3BSZWNJZHgoKTtcclxuICAgICAgICAgICAgICBsZXQgY3VyclJlY0lkeDogbnVtYmVyID0gdGhpcy5HZXREYXRhdmlldygpLmdldEN1cnJSZWNJZHgoKTtcclxuICAgICAgICAgICAgICBpZiAodG9wUmVjSWR4ID4gY3VyclJlY0lkeClcclxuICAgICAgICAgICAgICAgIHRoaXMuR2V0RGF0YXZpZXcoKS5zZXRUb3BSZWNJZHgoY3VyclJlY0lkeCk7XHJcbiAgICAgICAgICAgICAgcm93ID0gMDtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBhd2FpdCB0aGlzLnNldEN1cnJSb3dCeURpc3BsYXlMaW5lKHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRUb3BSZWNJZHgoKSArIHJvdywgZmFsc2UsIHRydWUpO1xyXG4gICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgICAgICBjYXRjaCAoZXgpIHtcclxuICAgICAgICAgIGlmIChleCBpbnN0YW5jZW9mIFJlY29yZE91dE9mRGF0YVZpZXdFeGNlcHRpb24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ICAgICAgIH1cclxuICAgICAgICAgIH1cclxuICAgICAgICAgIHRoaXMudXBkYXRlRGlzcGxheUxpbmVCeURWKCk7XHJcblxyXG4gICAgICAgICAgYXdhaXQgdGhpcy5SZWZyZXNoRGlzcGxheShDb25zdGFudHMuVEFTS19SRUZSRVNIX0ZPUk0pO1xyXG4gICAgICAgIH1cclxuICAgICAgICBjYXRjaCAoZXgpIHtcclxuICAgICAgICAgIGlmIChleCBpbnN0YW5jZW9mIFJlY29yZE91dE9mRGF0YVZpZXdFeGNlcHRpb24pXHJcbiAgICAgICAgICAgIExvZ2dlci5JbnN0YW5jZS5Xcml0ZURldlRvTG9nKGV4Lk1lc3NhZ2UpO1xyXG4gICAgICAgIH1cclxuICAgICAgfVxyXG4gICAgICAvLyBwYWdlIGFuZCByb3cgbW92ZW1lbnRzXHJcbiAgICAgIGVsc2Uge1xyXG4gICAgICAgIHRoaXMuZ2V0VG9wSW5kZXhGcm9tR1VJKCk7XHJcbiAgICAgICAgLy8gY2FsY3VsYXRlIHRoZSBhbW91bnQgb2YgcmVjb3JkcyB0byBza2lwXHJcbiAgICAgICAgbGV0IHNpemU6IG51bWJlcjtcclxuICAgICAgICBpZiAodW5pdCA9PT0gQ29uc3RhbnRzLk1PVkVfVU5JVF9QQUdFICYmIHRoaXMuaXNMaW5lTW9kZSgpKSB7XHJcbiAgICAgICAgICBzd2l0Y2ggKGRpcmVjdGlvbikge1xyXG4gICAgICAgICAgICBjYXNlIENvbnN0YW50cy5NT1ZFX0RJUkVDVElPTl9CRUdJTjpcclxuICAgICAgICAgICAgICBzaXplID0gdGhpcy5HZXREYXRhdmlldygpLmdldEN1cnJSZWNJZHgoKSAtIHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRUb3BSZWNJZHgoKTtcclxuICAgICAgICAgICAgICBicmVhaztcclxuICAgICAgICAgICAgY2FzZSBDb25zdGFudHMuTU9WRV9ESVJFQ1RJT05fRU5EOlxyXG5cclxuICAgICAgICAgICAgICBsZXQgbGFzdDogbnVtYmVyID0gdGhpcy5HZXREYXRhdmlldygpLmdldFRvcFJlY0lkeCgpICsgdGhpcy5fcm93c0luUGFnZSAtIDE7XHJcbiAgICAgICAgICAgICAgbGFzdCA9IE1hdGgubWluKGxhc3QsIHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRTaXplKCkgLSAxKTtcclxuICAgICAgICAgICAgICBzaXplID0gbGFzdCAtIHRoaXMuR2V0RGF0YXZpZXcoKS5nZXRDdXJyUmVjSWR4KCk7XHJcbiAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgIGRlZmF1bHQ6XHJcbiAgICAgICAgICAgICAgcmV0dXJuVG9WaXNpYmxlTGluZSA9IHRydWU7XHJcbiAgICAgICAgICAgICAgc2l6ZSA9IHRoaXMuX3Jvd3NJblBhZ2U7XHJcbiAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICB9XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGVsc2VcclxuICAgICAgICAgIHNpemUgPSAxO1xyXG5cclxuICAgICAgICBzaXplID0gKGRpcmVjdGlvbiA9PT0gQ29uc3RhbnRzLk1PVkVfRElSRUNUSU9OX1BSRVYgfHxcclxuICAgICAgICBkaXJlY3Rpb24gPT09IENvbnN0YW50cy5NT1ZFX0RJUkVDVElPTl9CRUdJTlxyXG4gICAgICAgICAgPyAtc2l6ZVxyXG4gICAgICAgICAgOiBzaXplKTtcclxuXHJcbiAgICAgICAgaWYgKHRoaXMuaXNMaW5lTW9kZSgpKSB7XHJcbiAgICAgICAgICB2aXNpYmxlTGluZSA9IHRoaXMuZ2V0VmlzaWJsZUxpbmUoKTtcclxuICAgICAgICAgIGlmICh2aXNpYmxlTGluZSA8IDApIHtcclxuICAgICAgICAgICAgdmlzaWJsZUxpbmUgPSAwO1xyXG4gICAgICAgICAgICByZWNvcmRPdXRPZlZpZXcgPSB0cnVlO1xyXG4gICAgICAgICAgfVxyXG4gICAgICAgICAgaWYgKHZpc2libGVMaW5lID4gdGhpcy5fcm93c0luUGFnZSArIDEpIHtcclxuICAgICAgICAgICAgdmlzaWJsZUxpbmUgPSB0aGlzLl9yb3dzSW5QYWdlO1xyXG4gICAgICAgICAgICByZWNvcmRPdXRPZlZpZXcgPSB0cnVlO1xyXG4gICAgICAgICAgfVxyXG4gICAgICAgICAgLy8gc2Nyb2xsaW5nIHRoZSB0YWJsZSBvbmUgcGFnZSBvciBvbmUgcm93IHVwIG9yIGRvd25cclxuICAgICAgICAgIGlmICh1bml0ID09PSBDb25zdGFudHMuTU9WRV9VTklUX1BBR0UgJiZcclxuICAgICAgICAgICAgKGRpcmVjdGlvbiA9PT0gQ29uc3RhbnRzLk1PVkVfRElSRUNUSU9OX05FWFQgfHxcclxuICAgICAgICAgICAgICBkaXJlY3Rpb24gPT09IENvbnN0YW50cy5NT1ZFX0RJUkVDVElPTl9QUkVWKSB8fFxyXG4gICAgICAgICAgICB1bml0ID09PSBDb25zdGFudHMuTU9WRV9VTklUX1JPVyAmJlxyXG4gICAgICAgICAgICAoZGlyZWN0aW9uID09PSBDb25zdGFudHMuTU9WRV9ESVJFQ1RJT05fTkVYVCAmJiB2aXNpYmxlTGluZSA9PT0gdGhpcy5fcm93c0luUGFnZSAtIDEgfHxcclxuICAgICAgICAgICAgICBkaXJlY3Rpb24gPT09IENvbnN0YW50cy5NT1ZFX0RJUkVDVElPTl9QUkVWICYmIHZpc2libGVMaW5lID09PSAwKSkge1xyXG4gICAgICAgICAgICAvLyBpZiB3ZSBtb3ZlIHRvIHRoZSBwcmV2aW91cyByb3cgYnV0IHdlIGFyZSBhdCB0aGUgZmlyc3Qgcm93IG9mIHRoZSB0YWJsZSBhbmQgZGF0YSB2aWV3XHJcbiAgICAgICAgICAgIC8vIHRoZW4gZG8gbm90aGluZ1xyXG4gICAgICAgICAgICBpZiAoZGlyZWN0aW9uID09PSBDb25zdGFudHMuTU9WRV9ESVJFQ1RJT05fUFJFViAmJlxyXG4gICAgICAgICAgICAgICh1bml0ID09PSB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ZXc+dGhpcy5HZXREYXRhdmlldygpKS5zZXRUb3BSZWNJZHhNb2RpZmllZCh0cnVlKTtcclxuICAgICAgICAgICAgdHJ5IHtcclxuICAgICAgICAgICAgICB0aGlzLl9zdWZmaXhEb25lID0gZmFsc2U7XHJcblxyXG4gICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2V0Q3VyclJvd0J5RGlzcGxheUxpbmUodGhpcy5HZXREYXRhdmlldygpLmdldEN1cnJSZWNJZHgoKSArIHNpemUsIHRydWUsIGZhbHNlKTtcclxuICAgICAgICAgICAgICAoPERhdGFWaWV3PnRoaXMuR2V0RGF0YXZpZXcoKSkuc2V0VG9wUmVjSWR4TW9kaWZpZWQoZmFsc2UpO1xyXG4gICAgICAgICAgICAgIGF3YWl0IHRoaXMuUmVmcmVzaERpc3BsYXkoQ29uc3RhbnRzLlRBU0tfUkVGUkVTSF9GT1JNKTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBjYXRjaCAoZXgpIHtcclxuICAgICAgICAgICAgICBpZiAoZXggaW5zdGFuY2VvZiBSZWNvcmRPdXRPZkRhdGFWaWV3RXhjZXB0aW9uKSB7XHJcbiAgICAgICAgICAgICAgICAoPERhdGFWaWV3PnRoaXMuR2V0RGF0YXZpZXcoKSkuc2V0VG9wUmVjSWR4TW9kaWZpZWQoZmFsc2UpO1xyXG4gICAgICAgICAgICAgICAgaWYgKEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLkdldFN0b3BFeGVjdXRpb25GbGFnKCkpIHtcclxuICAgICAgICAgICAgICAgICAgKDxEYXRhVmlldz50aGlzLkdldERhdGF2aWV3KCkpLnJlc3RvcmVUb3BSZWNJZHgoKTtcclxuICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5yZXN0b3JlT2xkRGlzcGxheUxpbmUob2xkRGlzcGxheUxpbmUpO1xyXG4gICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBpZiAodGhpcy5HZXREYXRhdmlldygpLmdldFRvcFJlY0lkeCgpIDwgMCkge1xyXG4gICAgICAgICAgICAgICAgICB0aGlzLkdldERhdGF2aWV3KCkuc2V0VG9wUmVjSWR4KDApO1xyXG4gICAgICAgICAgICAgICAgICB0cnkge1xyXG4gICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2V0Q3VyclJvd0J5RGlzcGxheUxpbmUoMCwgdHJ1ZSwgZmFsc2UpO1xyXG4gICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgIGNhdGNoIChleGNlcHRpb24pIHtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoZXhjZXB0aW9uIGluc3RhbmNlb2YgRXhjZXB0aW9uKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAvLyBRQ1IgIzk5NTQ5Njogd2hlbiB0aGUgcmVjb3JkIHN1ZmZpeCBmYWlsZWQgZ28gYmFjayB0byB0aGVcclxuICAgICAgICAgICAgICAgICAgICAgIC8vIG9yaWdpbmFsIHJvd1xyXG4gICAgICAgICAgICAgICAgICAgICAgaWYgKEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLkdldFN0b3BFeGVjdXRpb25GbGFnKCkpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgKDxEYXRhVmlldz50aGlzLkdldERhdGF2aWV3KCkpLnJlc3RvcmVUb3BSZWNJZHgoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5yZXN0b3JlT2xkRGlzcGxheUxpbmUob2xkRGlzcGxheUxpbmUpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuUmVmcmVzaERpc3BsYXkoQ29uc3RhbnRzLlRB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SkucmVzdG9yZVRvcFJlY0lkeCgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5yZXN0b3JlT2xkRGlzcGxheUxpbmUob2xkRGlzcGxheUxpbmUpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICB0cnkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5SZWZyZXNoRGlzcGxheShDb25zdGFudHMuVEFTS19SRUZSRVNIX0ZPUk0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5zZXRDdXJyUm93QnlEaXNwbGF5TGluZSh0aGlzLkdldERhdGF2aWV3KCkuZ2V0VG9wUmVjSWR4KCkgKyB0aGlzLmdldExhc3RWYWxpZFJvdygpLCBmYWxzZSwgdHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICB2aXNpYmxlTGluZSA9IHRoaXMuZ2V0TGFzdFZhbGlkUm93KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIGNhdGNoIChFeGNlcHRpb24pIHtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAoPERhdGFWaWV3PnRoaXMuR2V0RGF0YXZpZXcoKSkucmVzdG9yZVRvcFJlY0lkeCgpO1xyXG4gICAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLnJlc3RvcmVPbGREaXNwbGF5TGluZShvbGREaXNwbGF5TGluZSk7XHJcbiAgICAgICAgICAgICAgICAgIGlmICh1bml0ID09PSBDb25zdGFudHMuTU9WRV9VTklUX1JPVyAmJiBkaXJlY3Rpb24gPT09IENvbnN0YW50cy5NT1ZFX0RJUkVDVElPTl9ORVhUKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgLy8gbm9uIGludGVyYWN0aXZlLCBlbmQgb2YgZGF0YSBtZWFucyBlbmQgb2Ygb3duZXJUYXNrLCB1bmxlc3Mgd2UgYXJlIGluIGNyZWF0ZSBtb2RlLlxyXG4gICAgICAgICAgICAgICAgICAgIGlmICghdGhpcy5fdGFzay5Jc0ludGVyYWN0aXZlICYmIHRoaXMuX3Rhc2suZ2V0TW9kZSgpICE9PSBDb25zdGFudHMuVEFTS19NT0RFX0NSRUFURSlcclxuICAgICAgICAgICAgICAgICAgICAgICg8VGFza0Jhc2U+dGhpcy5fdGFzaykuc2V0RXhlY0VuZFRhc2soKTtcclxuICAgICAgICAgICAgICAgICAgICBlbHNlXHJcbiAgICAgICAgICAgICAgICAgICAgICBhd2FpdCBBY2Nlc3NIZWxwZXIuZXZlbnRzTWFuYWdlci5oYW5kbGVJbnRlcm5hbEV2ZW50V2l0aFRhc2sodGhpcy5fdGFzaywgSW50ZXJuYWxJbnRlcmZhY2UuTUdfQUNUX0NSRUxJTkUpO1xyXG4gICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIExvZ2dlci5JbnN0YW5jZS5Xcml0ZURldlRvTG9nKGV4Lk1lc3NhZ2UpO1xyXG4gICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgfVxyXG4gICAgICAgICAgLy8gbW92aW5nIHRoZSBtYXJraW5nIG9uZSByb3cgdXAgb3IgZG93blxyXG4gICAgICAgICAgZWxzZSB7XHJcbiAgICAgICAgICAgIHRyeSB7XHJcbiAgICAgICAgICAgICAgb2xkVGFza01vZGUgPSB0aGlzLl90YXNrLmdldE1vZGUoKTtcclxuXHJcbiAgICAgICAgICAgICAgb2xkUmVjSWQgPSAodGhpcy5HZXREYXRhdmlldygpLmdldEN1cnJSZWMoKSkuZ2V0SW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lYy5jbGVhck1vZGUoKTtcclxuICAgICAgICAgICAgICAgICAgICBjdXJyUmVjLnNldE1vZGUoRGF0YU1vZGlmaWNhdGlvblR5cGVzLkluc2VydCk7XHJcbiAgICAgICAgICAgICAgICAgICAgY3VyclJlYy5zZXROZXdSZWMoKTtcclxuICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAvLyBRQ1IgIzk4MDUyODogUmVmcmVzaCB0aGUgY3VycmVudCByb3cgYWZ0ZXIgY2FuY2VsIGVkaXQgdG8gcmVmbGVjdFxyXG4gICAgICAgICAgICAgICAgICAvLyB0aGUgcmVzdG9yZWQgdmFsdWVzXHJcbiAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuUmVmcmVzaERpc3BsYXkoQ29uc3RhbnRzLlRBU0tfUkVGUkVTSF9DVVJSX1JFQyk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgaWYgKG9sZFRhc2tNb2RlID09PSBDb25zdGFudHMuVEFTS19NT0RFX0NSRUFURSAmJiBvbGREaXNwbGF5TGluZSA+IDApXHJcbiAgICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5yZXN0b3JlT2xkRGlzcGxheUxpbmUob2xkRGlzcGxheUxpbmUgLSAxKTtcclxuICAgICAgICAgICAgICAgICAgYXdhaXQgdGhpcy5SZWZyZXNoRGlzcGxheShDb25zdGFudHMuVEFTS19SRUZSRVNIX0ZPUk0pO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgaWYgKHNpemUgPD0gMCB8fCBBY2Nlc3NIZWxwZXIuZXZlbnRzTWFuYWdlci5HZXRTdG9wRXhlY3V0aW9uRmxhZygpKVxyXG4gICAgICAgICAgICAgICAgICBMb2dnZXIuSW5zdGFuY2UuV3JpdGVEZXZUb0xvZyhleC5NZXNzYWdlKTtcclxuICAgICAgICAgICAgICAgIGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAvLyBub24gaW50ZXJhY3RpdmUsIGVuZCBvZiBkYXRhIG1lYW5zIGVuZCBvZiBvd25lclRhc2ssIHVubGVzcyB3ZSBhcmUgaW4gY3JlYXRlIG1vZGUuXHJcbiAgICAgICAgICAgICAgICAgIGlmICghdGhpcy5fdGFzay5Jc0ludGVyYWN0aXZlICYmIHRoaXMuX3Rhc2suZ2V0TW9kZSgpICE9PSBDb25zdGFudHMuVEFTS19NT0RFX0NSRUFURSkge1xyXG4gICAgICAgICAgICAgICAgICAgICg8VGFza0Jhc2U+dGhpcy5fdGFzaykuc2V0RXhlY0VuZFRhc2soKTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHRoaXMuX3Rhc2suQWN0aW9uTWFuYWdlci5pc0VuYWJsZWQoSW50ZXJuYWxJbnRlcmZhY2UuTUdfQUNUX0NSRUxJTkUpKVxyXG4gICAgICAgICAgICAgICAgICAgICAgYXdhaXQgQWNjZXNzSGVscGVyLmV2ZW50c01hbmFnZXIuaGFuZGxlSW50ZXJuYWxFdmVudFdpdGhUYXNrKHRoaXMuX3Rhc2ssIEludGVybmFsSW50ZXJmYWNlLk1HX0FDVF9DUkVMSU5FKTtcclxuICAgICAgICAgICAgICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAgIC8vIGZpeGVkIGJ1ZyAjOjk0MTc2Mywgd2hpbGUgY3JlYXRlIGlzbid0IGFsbG93ZWQgbmVlZCB0byBkbyBzdWZmaXggYW5kIHByZWZpeCBvZiB0aGUgY3VycmVudCByZWNvcmRcclxuICAgICAgICAgICAgICAgICAgICAgIGxldCBkb1JlY29yZFN1ZmZpeDogYm9vbGVhbiA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICBsZXQgcmVmZG9SZWNvcmRTdWZmaXg6IFJlZlBhcmFtPGJvb2xlYW4+ID0gbmV3IFJlZlBhcmFtKGRvUmVjb3JkU3VmZml4KTtcclxuICAgICAgICAgICAgICAgICAgICAgIGlmICghIGF3YWl0IEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLkRvVGFza0xldmVsUmVjb3JkU3VmZml4KDxUYXNrQmFzZT50aGlzLl90YXNrLCByZWZkb1JlY29yZFN1ZmZpeCkpXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLkRvVGFza0xldmVsUmVjb3JkUHJlZml4KHRoaXMuX3Rhc2spO1xyXG4gICAgICAgICAgICAgICAgICAgICAgZG9SZWNvcmRTdWZmaXggPSByZWZkb1JlY29yZFN1ZmZpeC52YWx1ZTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICAgICAgLy8gaWYgdGhlIGZvcm0gZG9lcyBub3QgaGF2ZSBhIHRhYmxlLCBtb3ZlIHRvIG9uZSByb3cgaW4gdGhlIGNob3NlbiBEaXJlY3Rpb25cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgIHRyeSB7XHJcbiAgICAgICAgICAgIGF3YWl0IHRoaXMuR2V0RGF0YXZpZXcoKS5zZXRDdXJyUmVjQnlJZHgodGhpcy5HZXREYXRhdmlldygpLmdldEN1cnJSZWNJZHgoKSArIHNpemUsIHRydWUsIGZhbHNlLCB0cnVlLCBTRVRfRElTUExBWUxJTkVfQllfRFYpO1xyXG4gICAgICAgICAgICBhd2FpdCB0aGlzLlJlZnJlc2hEaXNwbGF5KENvbnN0YW50cy5UQVNLX1JFRlJFU0hfRk9STSk7XHJcbiAgICAgICAgICB9XHJcbiAgICAgICAgICBjYXRjaCAoZXgpIHtcclxuICAgICAgICAgICAgaWYgKGV4IGluc3RhbmNlb2YgUmVjb3JkT3V0T2ZEYXRhVmlld0V4Y2VwdGlvbikge1xyXG4gICAgICAgICAgICAgIGlmIChzaXplID4gMCkge1xyXG4gICAgICAgICAgICAgICAgLy8gbm9uIGludGVyYWN0aXZlLCBlbmQgb2YgZGF0YSBtZWFucyBlbmQgb2Ygb3duZXJUYXNrLCB1bmxlc3Mgd2UgYXJlIGluIGNyZWF0ZSBtb2RlLlxyXG4gICAgICAgICAgICAgICAgaWYgKCF0aGlzLl90YXNrLklzSW50ZXJhY3RpdmUgJiYgdGhpcy5fdGFzay5nZXRNb2RlKCkgIT09IENvbnN0YW50cy5UQVNLX01PREVfQ1JFQVRFKVxyXG4gICAgICAgICAgICAgICAgICAoPFRhc2tCYXNlPnRoaXMuX3Rhc2spLnNldEV4ZWNFbmRUYXNrKCk7XHJcbiAgICAgICAgICAgICAgICBlbHNlXHJcbiAgICAgICAgICAgICAgICAgIGF3YWl0IEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLmhhbmRsZUludGVybmFsRXZlbnRXaXRoVGFzayh0aGlzLl90YXNrLCBJbnRlcm5hbEludGVyZmFjZS5NR19BQ1RfQ1JFTElORSk7XHJcbiAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgIGVsc2VcclxuICAgICAgICAgICAgICAgIExvZ2dlci5JbnN0YW5jZS5Xcml0ZURldlRvTG9nKGV4Lk1lc3NhZ2UpO1xyXG4gICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBlbHNlIGlmIChleCBpbnN0YW5jZW9mIFNlcnZlckVycm9yKSB7XHJcbiAgICAgICAgICAgICAgYXdhaXQgKDxUYXNrQmFzZT50aGlzLl90YXNrKS5zdG9wKCk7XHJcbiAgICAgICAgICAgICAgKDxUYXNrQmFzZT50aGlzLl90YXNrKS5hYm9ydCgpO1xyXG4gICAgICAgICAgICAgIGF3YWl0IEFjY2Vzc0hlbHBlci5ldmVudHNNYW5hZ2VyLlByb2Nlc3NBYm9ydGluZ0Vycm9yKGV4KTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBlbHNlIGlmIChleCBpbnN0YW5jZW9mIEV4Y2VwdGlvbikge1xyXG4gICAgICAgICAgICAgIExvZ2dlci5JbnN0YW5jZS5Xcml0ZURldlRvTG9nKGV4Lk1lc3NhZ2UpO1xyXG4gICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgICAgfVxyXG4gICAgICBpZiAocmV0dXJuVG9WaXNpYmxlTGluZSkge1xyXG4gICAgICAgIGlmIChyZWNvcmRPdXRPZlZpZXcpIHtcclxuICAgICAgICAgIGlmICh2aXNpYmxlTGluZSA9PT0gMClcclxuICAgICAgICAgICAgdGhpcy5HZXREYXRhdmlldygpLnNldFRvcFJlY0lkeCh0aGlzLkdldERhdGF2aWV3KCkuZ2V0Q3VyclJlY0lkeCgpKTtcclxuICAgICAgICAgIGVsc2VcclxuICAgICAgICAgICAgdGhpcy5HZXREYXRhdmlldygpLnNldFRvcFJlY0lkeCh0aGlzLkdldERhdGF2aWV3KCkuZ2V0Q3VyclJlY0lkeCgpIC0gdGhpcy5fcm93c0luUGFnZSk7XHJcbiAgICAgICAgICB0aGlzLlNldFRhYmxlVG9wSW5kZXgoKTtcclxuICAgICAgICB9XHJcbiAgICAgICAgZWxzZSB7XHJcbiAgICAgICAgICB0aGlzLlNldFRhYmxlVG9wSW5kZXgoKTtcclxuICAgICAgICAgIGF3YWl0IHRoaXMuc2V0Q3VyclJvd0J5RGlzcGxheUxpbmUodGhpcy5HZXREYXRhdmlldygpLmdldFRvcFJlY0lkeCgpICsgdmlzaWJsZUxpbmUsIGZhbHNlLCB0cnVlKTtcclxuICAgICAgICB9XHJcbiAgICAgIH1cclx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ldFRvcFJlY0lkeCgpO1xyXG4gICAgICAgICAgICAgIGxldCBjdXJyUmVjSWR4OiBudW1iZXIgPSB0aGlzLkdldERhdGF2aWV3KCkuZ2V0Q3VyclJlY0lkeCgpO1xyXG4gICAgICAgICAgICAgIGlmICh0b3BSZWNJZHggPiBjdXJyUmVjSWR4KVxyXG4gICAgICAgICAgICAgICAgdGhpcy5HZXREYXRhdmlldygpLnNldFRvcFJlY0lkeChjdXJyUmVjSWR4KTtcclxuICAgICAgICAgICAgICByb3cgPSAwO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIGF3YWl0IHRoaXMuc2V0Q3VyclJvd0J5RGlzcGxheUxpbmUodGhpcy5HZXREYXRhdmlldygpLmdldFRvcFJlY0lkeCgpICsgcm93LCBmYWxzZSwgdHJ1ZSk7XHJcbiAgICAgICAgICB9XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGNhdGNoIChleCkge1xyXG4gICAgICAgICAgaWYgKGV4IGluc3RhbmNlb2YgUmVjb3JkT3V0T2ZEYXRhVmlld0V4Y2VwdGlvbikge1xyXG4gICAgICAgICAgICAvLyBubyBleGNlcHRpb24gc2hvdWxkIHJlYWxseSBiZSBjYXVnaHQgaGVyZS5cclxuICAgICAgICAgICAgaWYgKHJvdyAhPT0gMClcclxuICAgICAgICAgICAgICBMb2dnZXIuSW5zdGFuY2UuV3JpdGVEZXZUb0xvZyhOU3RyaW5nLkZvcm1hdChcImluIEZvcm0uY2FuY2VsRWRpdCgpIHswfVwiLCBleC5NZXNzYWdlKSk7XHJcbiAgICAgICAgICB9XHJcbiAgICAgICAgICBlbHNlXHJcbiAgICAgICAgICAgIHRocm93IGV4O1xyXG4gICAgICAgIH1cclxuICAgICAgICBpZiAoc3VwZXIuSGFzVGFibGUoKSkge1xyXG4gICAgICAgICAgLy8gRGVjcmVtZW50IHRoZSBUb3RhbFJlY29yZHNDb3VudCBhcyByZWNvcmQgYmVpbmcgZGVsZXRlZC5cclxuICAgICAgICAgI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