@theia/core 1.45.1 → 1.46.1
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/README.md +6 -6
- package/i18n/nls.cs.json +4 -0
- package/i18n/nls.de.json +4 -0
- package/i18n/nls.es.json +4 -0
- package/i18n/nls.fr.json +4 -0
- package/i18n/nls.hu.json +4 -0
- package/i18n/nls.it.json +4 -0
- package/i18n/nls.ja.json +4 -0
- package/i18n/nls.json +4 -0
- package/i18n/nls.pl.json +4 -0
- package/i18n/nls.pt-br.json +4 -0
- package/i18n/nls.pt-pt.json +4 -0
- package/i18n/nls.ru.json +4 -0
- package/i18n/nls.zh-cn.json +4 -0
- package/lib/browser/browser.d.ts +3 -0
- package/lib/browser/browser.d.ts.map +1 -1
- package/lib/browser/browser.js +5 -1
- package/lib/browser/browser.js.map +1 -1
- package/lib/browser/common-frontend-contribution.d.ts.map +1 -1
- package/lib/browser/common-frontend-contribution.js +3 -3
- package/lib/browser/common-frontend-contribution.js.map +1 -1
- package/lib/browser/frontend-application-module.d.ts.map +1 -1
- package/lib/browser/frontend-application-module.js +2 -1
- package/lib/browser/frontend-application-module.js.map +1 -1
- package/lib/browser/tree/index.d.ts +1 -0
- package/lib/browser/tree/index.d.ts.map +1 -1
- package/lib/browser/tree/index.js +1 -0
- package/lib/browser/tree/index.js.map +1 -1
- package/lib/browser/tree/tree-preference.d.ts +11 -0
- package/lib/browser/tree/tree-preference.d.ts.map +1 -0
- package/lib/browser/tree/tree-preference.js +47 -0
- package/lib/browser/tree/tree-preference.js.map +1 -0
- package/lib/browser/tree/tree-widget.d.ts +6 -3
- package/lib/browser/tree/tree-widget.d.ts.map +1 -1
- package/lib/browser/tree/tree-widget.js +24 -3
- package/lib/browser/tree/tree-widget.js.map +1 -1
- package/lib/browser/tree/tree.d.ts.map +1 -1
- package/lib/browser/tree/tree.js +4 -1
- package/lib/browser/tree/tree.js.map +1 -1
- package/lib/browser/widget-manager.d.ts +9 -0
- package/lib/browser/widget-manager.d.ts.map +1 -1
- package/lib/browser/widget-manager.js +23 -0
- package/lib/browser/widget-manager.js.map +1 -1
- package/lib/browser/widgets/select-component.d.ts.map +1 -1
- package/lib/browser/widgets/select-component.js +1 -0
- package/lib/browser/widgets/select-component.js.map +1 -1
- package/lib/browser-only/frontend-only-application-module.d.ts +5 -0
- package/lib/browser-only/frontend-only-application-module.d.ts.map +1 -0
- package/lib/browser-only/frontend-only-application-module.js +115 -0
- package/lib/browser-only/frontend-only-application-module.js.map +1 -0
- package/lib/browser-only/i18n/i18n-frontend-only-module.d.ts +4 -0
- package/lib/browser-only/i18n/i18n-frontend-only-module.d.ts.map +1 -0
- package/lib/browser-only/i18n/i18n-frontend-only-module.js +35 -0
- package/lib/browser-only/i18n/i18n-frontend-only-module.js.map +1 -0
- package/lib/browser-only/logger-frontend-only-module.d.ts +3 -0
- package/lib/browser-only/logger-frontend-only-module.d.ts.map +1 -0
- package/lib/browser-only/logger-frontend-only-module.js +61 -0
- package/lib/browser-only/logger-frontend-only-module.js.map +1 -0
- package/lib/browser-only/messaging/frontend-only-service-connection-provider.d.ts +14 -0
- package/lib/browser-only/messaging/frontend-only-service-connection-provider.d.ts.map +1 -0
- package/lib/browser-only/messaging/frontend-only-service-connection-provider.js +57 -0
- package/lib/browser-only/messaging/frontend-only-service-connection-provider.js.map +1 -0
- package/lib/browser-only/messaging/messaging-frontend-only-module.d.ts +3 -0
- package/lib/browser-only/messaging/messaging-frontend-only-module.d.ts.map +1 -0
- package/lib/browser-only/messaging/messaging-frontend-only-module.js +48 -0
- package/lib/browser-only/messaging/messaging-frontend-only-module.js.map +1 -0
- package/lib/browser-only/preload/frontend-only-preload-module.d.ts +4 -0
- package/lib/browser-only/preload/frontend-only-preload-module.d.ts.map +1 -0
- package/lib/browser-only/preload/frontend-only-preload-module.js +52 -0
- package/lib/browser-only/preload/frontend-only-preload-module.js.map +1 -0
- package/lib/common/application-protocol.d.ts +1 -0
- package/lib/common/application-protocol.d.ts.map +1 -1
- package/lib/common/disposable.d.ts +9 -0
- package/lib/common/disposable.d.ts.map +1 -1
- package/lib/common/disposable.js +26 -1
- package/lib/common/disposable.js.map +1 -1
- package/lib/{node → common}/file-uri.d.ts +1 -1
- package/lib/common/file-uri.d.ts.map +1 -0
- package/lib/{node → common}/file-uri.js +2 -2
- package/lib/common/file-uri.js.map +1 -0
- package/lib/common/menu/menu-model-registry.d.ts +2 -2
- package/lib/common/menu/menu-model-registry.d.ts.map +1 -1
- package/lib/common/menu/menu-model-registry.js +16 -2
- package/lib/common/menu/menu-model-registry.js.map +1 -1
- package/lib/common/menu/menu.spec.js +28 -1
- package/lib/common/menu/menu.spec.js.map +1 -1
- package/lib/common/message-rpc/msg-pack-extension-manager.d.ts +1 -1
- package/lib/common/message-rpc/msg-pack-extension-manager.js +1 -1
- package/lib/common/message-rpc/rpc-protocol.d.ts +3 -1
- package/lib/common/message-rpc/rpc-protocol.d.ts.map +1 -1
- package/lib/common/message-rpc/rpc-protocol.js +19 -1
- package/lib/common/message-rpc/rpc-protocol.js.map +1 -1
- package/lib/common/messaging/proxy-factory.d.ts.map +1 -1
- package/lib/common/messaging/proxy-factory.js +1 -8
- package/lib/common/messaging/proxy-factory.js.map +1 -1
- package/lib/common/quick-pick-service.d.ts +1 -1
- package/lib/common/quick-pick-service.d.ts.map +1 -1
- package/lib/common/uuid.d.ts +6 -0
- package/lib/common/uuid.d.ts.map +1 -1
- package/lib/common/uuid.js +13 -1
- package/lib/common/uuid.js.map +1 -1
- package/lib/electron-main/electron-main-application.js +1 -1
- package/lib/electron-main/electron-main-application.js.map +1 -1
- package/lib/electron-main/theia-electron-window.js +1 -1
- package/lib/electron-main/theia-electron-window.js.map +1 -1
- package/lib/node/application-server.d.ts +1 -0
- package/lib/node/application-server.d.ts.map +1 -1
- package/lib/node/application-server.js +7 -1
- package/lib/node/application-server.js.map +1 -1
- package/lib/node/env-variables/env-variables-server.js +1 -1
- package/lib/node/env-variables/env-variables-server.js.map +1 -1
- package/lib/node/file-uri.spec.js +1 -1
- package/lib/node/file-uri.spec.js.map +1 -1
- package/lib/node/index.d.ts +1 -1
- package/lib/node/index.d.ts.map +1 -1
- package/lib/node/index.js +1 -1
- package/lib/node/index.js.map +1 -1
- package/package.json +10 -6
- package/src/browser/browser.ts +6 -1
- package/src/browser/common-frontend-contribution.ts +3 -3
- package/src/browser/frontend-application-module.ts +2 -1
- package/src/browser/style/select-component.css +12 -13
- package/src/browser/tree/index.ts +1 -0
- package/src/browser/tree/tree-preference.ts +50 -0
- package/src/browser/tree/tree-widget.tsx +24 -5
- package/src/browser/tree/tree.ts +2 -1
- package/src/browser/widget-manager.ts +25 -0
- package/src/browser/widgets/select-component.tsx +1 -0
- package/src/browser-only/frontend-only-application-module.ts +115 -0
- package/src/browser-only/i18n/i18n-frontend-only-module.ts +37 -0
- package/src/browser-only/logger-frontend-only-module.ts +63 -0
- package/src/browser-only/messaging/frontend-only-service-connection-provider.ts +39 -0
- package/src/browser-only/messaging/messaging-frontend-only-module.ts +42 -0
- package/src/browser-only/preload/frontend-only-preload-module.ts +49 -0
- package/src/common/application-protocol.ts +1 -0
- package/src/common/disposable.ts +25 -0
- package/src/{node → common}/file-uri.ts +2 -2
- package/src/common/menu/menu-model-registry.ts +22 -5
- package/src/common/menu/menu.spec.ts +30 -2
- package/src/common/message-rpc/msg-pack-extension-manager.ts +1 -1
- package/src/common/message-rpc/rpc-protocol.ts +22 -2
- package/src/common/messaging/proxy-factory.ts +1 -8
- package/src/common/quick-pick-service.ts +1 -1
- package/src/common/uuid.ts +13 -0
- package/src/electron-main/electron-main-application.ts +1 -1
- package/src/electron-main/theia-electron-window.ts +1 -1
- package/src/node/application-server.ts +8 -1
- package/src/node/env-variables/env-variables-server.ts +1 -1
- package/src/node/file-uri.spec.ts +1 -1
- package/src/node/index.ts +1 -1
- package/lib/node/file-uri.d.ts.map +0 -1
- package/lib/node/file-uri.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theia-electron-window.js","sourceRoot":"","sources":["../../src/electron-main/theia-electron-window.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;AAGhF,qFAA4F;AAC5F,6DAAgG;AAChG,sDAA2E;AAC3E,uEAA2E;AAC3E,sCAAiE;AACjE,+CAAyD;AACzD,uCAAoC;AACpC
|
|
1
|
+
{"version":3,"file":"theia-electron-window.js","sourceRoot":"","sources":["../../src/electron-main/theia-electron-window.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;AAGhF,qFAA4F;AAC5F,6DAAgG;AAChG,sDAA2E;AAC3E,uEAA2E;AAC3E,sCAAiE;AACjE,+CAAyD;AACzD,uCAAoC;AACpC,iDAA6C;AAC7C,2DAAuD;AAgB1C,QAAA,yBAAyB,GAAG,MAAM,CAAC,2BAA2B,CAAC,CAAC;AAEhE,QAAA,uBAAuB,GAAG,MAAM,CAAC,yBAAyB,CAAC,CAAC;AAGzE,IAAK,YAIJ;AAJD,WAAK,YAAY;IACb,qDAAO,CAAA;IACP,2DAAU,CAAA;IACV,+DAAY,CAAA;AAChB,CAAC,EAJI,YAAY,KAAZ,YAAY,QAIhB;AAGD,IAAa,mBAAmB,GAAhC,MAAa,mBAAmB;IAAhC;QAKc,sBAAiB,GAAG,IAAI,gBAAO,EAAQ,CAAC;QAM/B,cAAS,GAA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ationServerImpl implements ApplicationServer {
|
|
|
5
5
|
protected readonly applicationPackage: ApplicationPackage;
|
|
6
6
|
getExtensionsInfos(): Promise<ExtensionInfo[]>;
|
|
7
7
|
getApplicationInfo(): Promise<ApplicationInfo | undefined>;
|
|
8
|
+
getApplicationRoot(): Promise<string>;
|
|
8
9
|
getBackendOS(): Promise<OS.Type>;
|
|
9
10
|
}
|
|
10
11
|
//# sourceMappingURL=application-server.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"application-server.d.ts","sourceRoot":"","sources":["../../src/node/application-server.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,iBAAiB,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACnG,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAElC,qBACa,qBAAsB,YAAW,iBAAiB;IAG3D,SAAS,CAAC,QAAQ,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;IAE1D,kBAAkB,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;IAM9C,kBAAkB,IAAI,OAAO,CAAC,eAAe,GAAG,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"application-server.d.ts","sourceRoot":"","sources":["../../src/node/application-server.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,iBAAiB,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACnG,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAElC,qBACa,qBAAsB,YAAW,iBAAiB;IAG3D,SAAS,CAAC,QAAQ,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;IAE1D,kBAAkB,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;IAM9C,kBAAkB,IAAI,OAAO,CAAC,eAAe,GAAG,SAAS,CAAC;IAc1D,kBAAkB,IAAI,OAAO,CAAC,MAAM,CAAC;IAI/B,YAAY,IAAI,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC;CAGzC"}
|
|
@@ -39,10 +39,16 @@ let ApplicationServerImpl = class ApplicationServerImpl {
|
|
|
39
39
|
if (pck.name && pck.version) {
|
|
40
40
|
const name = pck.name;
|
|
41
41
|
const version = pck.version;
|
|
42
|
-
return Promise.resolve({
|
|
42
|
+
return Promise.resolve({
|
|
43
|
+
name,
|
|
44
|
+
version
|
|
45
|
+
});
|
|
43
46
|
}
|
|
44
47
|
return Promise.resolve(undefined);
|
|
45
48
|
}
|
|
49
|
+
getApplicationRoot() {
|
|
50
|
+
return Promise.resolve(this.applicationPackage.projectPath);
|
|
51
|
+
}
|
|
46
52
|
async getBackendOS() {
|
|
47
53
|
return os_1.OS.type();
|
|
48
54
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"application-server.js","sourceRoot":"","sources":["../../src/node/application-server.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;AAEhF,yCAA+C;AAE/C,oEAAgE;AAChE,qCAAkC;AAGlC,IAAa,qBAAqB,GAAlC,MAAa,qBAAqB;IAK9B,kBAAkB;QACd,MAAM,UAAU,GAAG,IAAI,CAAC,kBAAkB,CAAC,iBAAiB,CAAC;QAC7D,MAAM,KAAK,GAAoB,UAAU,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,CAAC,IAAI,EAAE,OAAO,EAAE,SAAS,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;QACnH,OAAO,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAClC,CAAC;IAED,kBAAkB;QACd,MAAM,GAAG,GAAG,IAAI,CAAC,kBAAkB,CAAC,GAAG,CAAC;QACxC,IAAI,GAAG,CAAC,IAAI,IAAI,GAAG,CAAC,OAAO,EAAE;YACzB,MAAM,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;YACtB,MAAM,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC;YAE5B,OAAO,OAAO,CAAC,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"application-server.js","sourceRoot":"","sources":["../../src/node/application-server.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;AAEhF,yCAA+C;AAE/C,oEAAgE;AAChE,qCAAkC;AAGlC,IAAa,qBAAqB,GAAlC,MAAa,qBAAqB;IAK9B,kBAAkB;QACd,MAAM,UAAU,GAAG,IAAI,CAAC,kBAAkB,CAAC,iBAAiB,CAAC;QAC7D,MAAM,KAAK,GAAoB,UAAU,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,CAAC,IAAI,EAAE,OAAO,EAAE,SAAS,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;QACnH,OAAO,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAClC,CAAC;IAED,kBAAkB;QACd,MAAM,GAAG,GAAG,IAAI,CAAC,kBAAkB,CAAC,GAAG,CAAC;QACxC,IAAI,GAAG,CAAC,IAAI,IAAI,GAAG,CAAC,OAAO,EAAE;YACzB,MAAM,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;YACtB,MAAM,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC;YAE5B,OAAO,OAAO,CAAC,OAAO,CAAC;gBACnB,IAAI;gBACJ,OAAO;aACV,CAAC,CAAC;SACN;QACD,OAAO,OAAO,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IACtC,CAAC;IAED,kBAAkB;QACd,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,kBAAkB,CAAC,WAAW,CAAC,CAAC;IAChE,CAAC;IAED,KAAK,CAAC,YAAY;QACd,OAAO,OAAE,CAAC,IAAI,EAAE,CAAC;IACrB,CAAC;CACJ,CAAA;AA7BG;IADC,IAAA,kBAAM,EAAC,wCAAkB,CAAC;8BACY,wCAAkB;iEAAC;AAHjD,qBAAqB;IADjC,IAAA,sBAAU,GAAE;GACA,qBAAqB,CAgCjC;AAhCY,sDAAqB"}
|
|
@@ -31,7 +31,7 @@ const inversify_1 = require("inversify");
|
|
|
31
31
|
const drivelist = require("drivelist");
|
|
32
32
|
const fs_extra_1 = require("fs-extra");
|
|
33
33
|
const os_2 = require("../../common/os");
|
|
34
|
-
const file_uri_1 = require("
|
|
34
|
+
const file_uri_1 = require("../../common/file-uri");
|
|
35
35
|
let EnvVariablesServerImpl = class EnvVariablesServerImpl {
|
|
36
36
|
constructor() {
|
|
37
37
|
this.envs = {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"env-variables-server.js","sourceRoot":"","sources":["../../../src/node/env-variables/env-variables-server.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,oDAAoD;AACpD,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;AAEhF,+BAA4B;AAC5B,2BAA6B;AAC7B,yCAAuC;AACvC,uCAAuC;AACvC,uCAA6C;AAE7C,wCAA4C;AAC5C,
|
|
1
|
+
{"version":3,"file":"env-variables-server.js","sourceRoot":"","sources":["../../../src/node/env-variables/env-variables-server.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,oDAAoD;AACpD,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;AAEhF,+BAA4B;AAC5B,2BAA6B;AAC7B,yCAAuC;AACvC,uCAAuC;AACvC,uCAA6C;AAE7C,wCAA4C;AAC5C,oDAAgD;AAGhD,IAAa,sBAAsB,GAAnC,MAAa,sBAAsB;IAO/B;QALmB,SAAI,GAAmC,EAAE,CAAC;QAC1C,eAAU,GAAG,kBAAO,CAAC,MAAM,CAAC,IAAA,YAAO,GAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;QAElD,uBAAkB,GAA+B,EAAE,CAAC;QAGnE,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,kBAAkB,EAAE,CAAC;QAC9C,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,YAAY,CAAC,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,iCAAiC,YAAY,GAAG,CAAC,CAAC,CAAC;QACtG,MAAM,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC;QAC1B,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,GAAW,EAAE,EAAE;YACvC,IAAI,OAAO,GAAG,GAAG,CAAC;YAClB,IAAI,cAAS,EAAE;gBACX,OAAO,GAAG,GAAG,CAAC,WAAW,EAAE,CAAC;aAC/B;YACD,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC;QAClE,CAAC,CAAC,CAAC;IAC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object.defineProperty(exports, "__esModule", { value: true });
|
|
|
18
18
|
const os = require("os");
|
|
19
19
|
const path = require("path");
|
|
20
20
|
const chai = require("chai");
|
|
21
|
-
const file_uri_1 = require("
|
|
21
|
+
const file_uri_1 = require("../common/file-uri");
|
|
22
22
|
const os_1 = require("../common/os");
|
|
23
23
|
const expect = chai.expect;
|
|
24
24
|
describe('file-uri', () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-uri.spec.js","sourceRoot":"","sources":["../../src/node/file-uri.spec.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;AAEhF,yBAAyB;AACzB,6BAA6B;AAC7B,6BAA6B;AAC7B,
|
|
1
|
+
{"version":3,"file":"file-uri.spec.js","sourceRoot":"","sources":["../../src/node/file-uri.spec.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;AAEhF,yBAAyB;AACzB,6BAA6B;AAC7B,6BAA6B;AAC7B,iDAA6C;AAC7C,qCAAyC;AAEzC,MAAM,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;AAE3B,QAAQ,CAAC,UAAU,EAAE,GAAG,EAAE;IAEtB,MAAM,SAAS,GAAa,CAAC,UAAU,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,YAAY,CAAC,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CA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M,GAAG,kBAAO,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC;QAC9C,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IACvC,CAAC,CAAC,CAAC;AACP,CAAC,CAAC,CAAC"}
|
package/lib/node/index.d.ts
CHANGED
package/lib/node/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/node/index.ts"],"names":[],"mappings":"AAgBA,cAAc,uBAAuB,CAAC;AACtC,cAAc,SAAS,CAAC;AACxB,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/node/index.ts"],"names":[],"mappings":"AAgBA,cAAc,uBAAuB,CAAC;AACtC,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC"}
|
package/lib/node/index.js
CHANGED
|
@@ -28,7 +28,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
28
28
|
exports.FileSystemLocking = void 0;
|
|
29
29
|
__exportStar(require("./backend-application"), exports);
|
|
30
30
|
__exportStar(require("./debug"), exports);
|
|
31
|
-
__exportStar(require("
|
|
31
|
+
__exportStar(require("../common/file-uri"), exports);
|
|
32
32
|
__exportStar(require("./messaging"), exports);
|
|
33
33
|
__exportStar(require("./cli"), exports);
|
|
34
34
|
var filesystem_locking_1 = require("./filesystem-locking");
|
package/lib/node/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/node/index.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;;AAEhF,wDAAsC;AACtC,0CAAwB;AACxB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/node/index.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;;;;;;;;;;AAEhF,wDAAsC;AACtC,0CAAwB;AACxB,qDAAmC;AACnC,8CAA4B;AAC5B,wCAAsB;AACtB,2DAAyD;AAAhD,uHAAA,iBAAiB,OAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theia/core",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.46.1",
|
|
4
4
|
"description": "Theia is a cloud & desktop IDE framework implemented in TypeScript.",
|
|
5
5
|
"main": "lib/common/index.js",
|
|
6
6
|
"typings": "lib/common/index.d.ts",
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"@phosphor/signaling": "1",
|
|
17
17
|
"@phosphor/virtualdom": "1",
|
|
18
18
|
"@phosphor/widgets": "1",
|
|
19
|
-
"@theia/application-package": "1.
|
|
20
|
-
"@theia/request": "1.
|
|
19
|
+
"@theia/application-package": "1.46.1",
|
|
20
|
+
"@theia/request": "1.46.1",
|
|
21
21
|
"@types/body-parser": "^1.16.4",
|
|
22
22
|
"@types/cookie": "^0.3.3",
|
|
23
23
|
"@types/dompurify": "^2.2.2",
|
|
@@ -134,8 +134,12 @@
|
|
|
134
134
|
"frontendPreload": "lib/browser/preload/preload-module",
|
|
135
135
|
"preload": "lib/electron-browser/preload"
|
|
136
136
|
},
|
|
137
|
+
{
|
|
138
|
+
"frontendOnlyPreload": "lib/browser-only/preload/frontend-only-preload-module"
|
|
139
|
+
},
|
|
137
140
|
{
|
|
138
141
|
"frontend": "lib/browser/i18n/i18n-frontend-module",
|
|
142
|
+
"frontendOnly": "lib/browser-only/i18n/i18n-frontend-only-module",
|
|
139
143
|
"backend": "lib/node/i18n/i18n-backend-module"
|
|
140
144
|
},
|
|
141
145
|
{
|
|
@@ -200,12 +204,12 @@
|
|
|
200
204
|
"watch": "theiaext watch"
|
|
201
205
|
},
|
|
202
206
|
"devDependencies": {
|
|
203
|
-
"@theia/ext-scripts": "1.
|
|
204
|
-
"@theia/re-exports": "1.
|
|
207
|
+
"@theia/ext-scripts": "1.46.1",
|
|
208
|
+
"@theia/re-exports": "1.46.1",
|
|
205
209
|
"minimist": "^1.2.0"
|
|
206
210
|
},
|
|
207
211
|
"nyc": {
|
|
208
212
|
"extends": "../../configs/nyc.json"
|
|
209
213
|
},
|
|
210
|
-
"gitHead": "
|
|
214
|
+
"gitHead": "1799210a8fba6eb81e2ddaf66f09d6fa071df012"
|
|
211
215
|
}
|
package/src/browser/browser.ts
CHANGED
|
@@ -18,6 +18,8 @@
|
|
|
18
18
|
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
19
19
|
*--------------------------------------------------------------------------------------------*/
|
|
20
20
|
|
|
21
|
+
import { environment } from '../common';
|
|
22
|
+
|
|
21
23
|
const userAgent = typeof navigator !== 'undefined' ? navigator.userAgent : '';
|
|
22
24
|
|
|
23
25
|
export const isIE = (userAgent.indexOf('Trident') >= 0);
|
|
@@ -31,7 +33,10 @@ export const isChrome = (userAgent.indexOf('Chrome') >= 0);
|
|
|
31
33
|
export const isSafari = (userAgent.indexOf('Chrome') === -1) && (userAgent.indexOf('Safari') >= 0);
|
|
32
34
|
export const isIPad = (userAgent.indexOf('iPad') >= 0);
|
|
33
35
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
34
|
-
|
|
36
|
+
/**
|
|
37
|
+
* @deprecated us Environment.electron.is
|
|
38
|
+
*/
|
|
39
|
+
export const isNative = environment.electron.is();
|
|
35
40
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
36
41
|
export const isBasicWasmSupported = typeof (window as any).WebAssembly !== 'undefined';
|
|
37
42
|
|
|
@@ -351,12 +351,12 @@ export namespace CommonCommands {
|
|
|
351
351
|
});
|
|
352
352
|
}
|
|
353
353
|
|
|
354
|
-
export const supportCut =
|
|
355
|
-
export const supportCopy =
|
|
354
|
+
export const supportCut = environment.electron.is() || document.queryCommandSupported('cut');
|
|
355
|
+
export const supportCopy = environment.electron.is() || document.queryCommandSupported('copy');
|
|
356
356
|
// Chrome incorrectly returns true for document.queryCommandSupported('paste')
|
|
357
357
|
// when the paste feature is available but the calling script has insufficient
|
|
358
358
|
// privileges to actually perform the action
|
|
359
|
-
export const supportPaste =
|
|
359
|
+
export const supportPaste = environment.electron.is() || (!browser.isChrome && document.queryCommandSupported('paste'));
|
|
360
360
|
|
|
361
361
|
export const RECENT_COMMANDS_STORAGE_KEY = 'commands';
|
|
362
362
|
|
|
@@ -139,6 +139,7 @@ import { bindCommonStylingParticipants } from './common-styling-participants';
|
|
|
139
139
|
import { HoverService } from './hover-service';
|
|
140
140
|
import { AdditionalViewsMenuWidget, AdditionalViewsMenuWidgetFactory } from './shell/additional-views-menu-widget';
|
|
141
141
|
import { LanguageIconLabelProvider } from './language-icon-provider';
|
|
142
|
+
import { bindTreePreferences } from './tree';
|
|
142
143
|
|
|
143
144
|
export { bindResourceProvider, bindMessageService, bindPreferenceService };
|
|
144
145
|
|
|
@@ -346,7 +347,6 @@ export const frontendApplicationModule = new ContainerModule((bind, _unbind, _is
|
|
|
346
347
|
});
|
|
347
348
|
bind(FrontendConnectionStatusService).toSelf().inSingletonScope();
|
|
348
349
|
bind(ConnectionStatusService).toService(FrontendConnectionStatusService);
|
|
349
|
-
bind(FrontendApplicationContribution).toService(FrontendConnectionStatusService);
|
|
350
350
|
bind(ApplicationConnectionStatusContribution).toSelf().inSingletonScope();
|
|
351
351
|
bind(FrontendApplicationContribution).toService(ApplicationConnectionStatusContribution);
|
|
352
352
|
|
|
@@ -366,6 +366,7 @@ export const frontendApplicationModule = new ContainerModule((bind, _unbind, _is
|
|
|
366
366
|
bind(ThemeService).toSelf().inSingletonScope();
|
|
367
367
|
|
|
368
368
|
bindCorePreferences(bind);
|
|
369
|
+
bindTreePreferences(bind);
|
|
369
370
|
|
|
370
371
|
bind(MimeService).toSelf().inSingletonScope();
|
|
371
372
|
|
|
@@ -14,6 +14,13 @@
|
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
16
|
|
|
17
|
+
.theia-select-component-container {
|
|
18
|
+
/* required to set z-index */
|
|
19
|
+
position: fixed;
|
|
20
|
+
/* dialog overlay has a z-index of 5000 */
|
|
21
|
+
z-index: 6000;
|
|
22
|
+
}
|
|
23
|
+
|
|
17
24
|
.theia-select-component {
|
|
18
25
|
background-color: var(--theia-dropdown-background);
|
|
19
26
|
cursor: pointer;
|
|
@@ -64,33 +71,25 @@
|
|
|
64
71
|
padding: 6px 5px;
|
|
65
72
|
}
|
|
66
73
|
|
|
67
|
-
.theia-select-component-dropdown
|
|
68
|
-
.theia-select-component-description:first-child {
|
|
74
|
+
.theia-select-component-dropdown .theia-select-component-description:first-child {
|
|
69
75
|
border-bottom: 1px solid var(--theia-editorWidget-border);
|
|
70
76
|
margin-bottom: 2px;
|
|
71
77
|
}
|
|
72
78
|
|
|
73
|
-
.theia-select-component-dropdown
|
|
74
|
-
.theia-select-component-description:last-child {
|
|
79
|
+
.theia-select-component-dropdown .theia-select-component-description:last-child {
|
|
75
80
|
border-top: 1px solid var(--theia-editorWidget-border);
|
|
76
81
|
margin-top: 2px;
|
|
77
82
|
}
|
|
78
83
|
|
|
79
|
-
.theia-select-component-dropdown
|
|
80
|
-
.theia-select-component-option
|
|
81
|
-
.theia-select-component-option-value {
|
|
84
|
+
.theia-select-component-dropdown .theia-select-component-option .theia-select-component-option-value {
|
|
82
85
|
width: 100%;
|
|
83
86
|
}
|
|
84
87
|
|
|
85
|
-
.theia-select-component-dropdown
|
|
86
|
-
.theia-select-component-option
|
|
87
|
-
.theia-select-component-option-detail {
|
|
88
|
+
.theia-select-component-dropdown .theia-select-component-option .theia-select-component-option-detail {
|
|
88
89
|
padding-left: 4px;
|
|
89
90
|
}
|
|
90
91
|
|
|
91
|
-
.theia-select-component-dropdown
|
|
92
|
-
.theia-select-component-option:not(.selected)
|
|
93
|
-
.theia-select-component-option-detail {
|
|
92
|
+
.theia-select-component-dropdown .theia-select-component-option:not(.selected) .theia-select-component-option-detail {
|
|
94
93
|
color: var(--theia-textLink-foreground);
|
|
95
94
|
}
|
|
96
95
|
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2024 STMicroelectronics and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
import { interfaces } from 'inversify';
|
|
18
|
+
import { PreferenceProxy, PreferenceContribution, PreferenceSchema } from '../preferences';
|
|
19
|
+
import { PreferenceProxyFactory } from '../preferences/injectable-preference-proxy';
|
|
20
|
+
import { nls } from '../../common/nls';
|
|
21
|
+
|
|
22
|
+
export const PREFERENCE_NAME_TREE_INDENT = 'workbench.tree.indent';
|
|
23
|
+
|
|
24
|
+
export const treePreferencesSchema: PreferenceSchema = {
|
|
25
|
+
type: 'object',
|
|
26
|
+
properties: {
|
|
27
|
+
[PREFERENCE_NAME_TREE_INDENT]: {
|
|
28
|
+
description: nls.localizeByDefault('Controls tree indentation in pixels.'),
|
|
29
|
+
type: 'number',
|
|
30
|
+
default: 8,
|
|
31
|
+
minimum: 4,
|
|
32
|
+
maximum: 40
|
|
33
|
+
},
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export class TreeConfiguration {
|
|
38
|
+
[PREFERENCE_NAME_TREE_INDENT]: number;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export const TreePreferences = Symbol('treePreferences');
|
|
42
|
+
export type TreePreferences = PreferenceProxy<TreeConfiguration>;
|
|
43
|
+
|
|
44
|
+
export function bindTreePreferences(bind: interfaces.Bind): void {
|
|
45
|
+
bind(TreePreferences).toDynamicValue(ctx => {
|
|
46
|
+
const factory = ctx.container.get<PreferenceProxyFactory>(PreferenceProxyFactory);
|
|
47
|
+
return factory(treePreferencesSchema);
|
|
48
|
+
}).inSingletonScope();
|
|
49
|
+
bind(PreferenceContribution).toConstantValue({ schema: treePreferencesSchema });
|
|
50
|
+
}
|
|
@@ -43,6 +43,8 @@ import { LabelProvider } from '../label-provider';
|
|
|
43
43
|
import { CorePreferences } from '../core-preferences';
|
|
44
44
|
import { TreeFocusService } from './tree-focus-service';
|
|
45
45
|
import { useEffect } from 'react';
|
|
46
|
+
import { PreferenceService, PreferenceChange } from '../preferences';
|
|
47
|
+
import { PREFERENCE_NAME_TREE_INDENT } from './tree-preference';
|
|
46
48
|
|
|
47
49
|
const debounce = require('lodash.debounce');
|
|
48
50
|
|
|
@@ -73,8 +75,7 @@ export interface TreeProps {
|
|
|
73
75
|
readonly contextMenuPath?: MenuPath;
|
|
74
76
|
|
|
75
77
|
/**
|
|
76
|
-
* The size of the padding (in pixels)
|
|
77
|
-
* the padding for the children will be calculated as `leftPadding * hierarchyDepth` and so on.
|
|
78
|
+
* The size of the padding (in pixels) for the root node of the tree.
|
|
78
79
|
*/
|
|
79
80
|
readonly leftPadding: number;
|
|
80
81
|
|
|
@@ -174,6 +175,9 @@ export class TreeWidget extends ReactWidget implements StatefulWidget {
|
|
|
174
175
|
@inject(SelectionService)
|
|
175
176
|
protected readonly selectionService: SelectionService;
|
|
176
177
|
|
|
178
|
+
@inject(PreferenceService)
|
|
179
|
+
protected readonly preferenceService: PreferenceService;
|
|
180
|
+
|
|
177
181
|
@inject(LabelProvider)
|
|
178
182
|
protected readonly labelProvider: LabelProvider;
|
|
179
183
|
|
|
@@ -182,6 +186,8 @@ export class TreeWidget extends ReactWidget implements StatefulWidget {
|
|
|
182
186
|
|
|
183
187
|
protected shouldScrollToRow = true;
|
|
184
188
|
|
|
189
|
+
protected treeIndent: number = 8;
|
|
190
|
+
|
|
185
191
|
constructor(
|
|
186
192
|
@inject(TreeProps) readonly props: TreeProps,
|
|
187
193
|
@inject(TreeModel) readonly model: TreeModel,
|
|
@@ -198,6 +204,7 @@ export class TreeWidget extends ReactWidget implements StatefulWidget {
|
|
|
198
204
|
|
|
199
205
|
@postConstruct()
|
|
200
206
|
protected init(): void {
|
|
207
|
+
this.treeIndent = this.preferenceService.get(PREFERENCE_NAME_TREE_INDENT, this.treeIndent);
|
|
201
208
|
if (this.props.search) {
|
|
202
209
|
this.searchBox = this.searchBoxFactory({ ...SearchBoxProps.DEFAULT, showButtons: true, showFilter: true });
|
|
203
210
|
this.searchBox.node.addEventListener('focus', () => {
|
|
@@ -264,6 +271,12 @@ export class TreeWidget extends ReactWidget implements StatefulWidget {
|
|
|
264
271
|
return;
|
|
265
272
|
}
|
|
266
273
|
}
|
|
274
|
+
}),
|
|
275
|
+
this.preferenceService.onPreferenceChanged((event: PreferenceChange) => {
|
|
276
|
+
if (event.preferenceName === PREFERENCE_NAME_TREE_INDENT) {
|
|
277
|
+
this.treeIndent = event.newValue;
|
|
278
|
+
this.update();
|
|
279
|
+
}
|
|
267
280
|
})
|
|
268
281
|
]);
|
|
269
282
|
setTimeout(() => {
|
|
@@ -1227,12 +1240,15 @@ export class TreeWidget extends ReactWidget implements StatefulWidget {
|
|
|
1227
1240
|
|
|
1228
1241
|
/**
|
|
1229
1242
|
* Handle the `space key` keyboard event.
|
|
1230
|
-
* -
|
|
1243
|
+
* - If the element has a checkbox, it will be toggled.
|
|
1244
|
+
* - Otherwise, it should be similar to a single-click action.
|
|
1231
1245
|
* @param event the `space key` keyboard event.
|
|
1232
1246
|
*/
|
|
1233
1247
|
protected handleSpace(event: KeyboardEvent): void {
|
|
1234
1248
|
const { focusedNode } = this.focusService;
|
|
1235
|
-
if (
|
|
1249
|
+
if (focusedNode && focusedNode.checkboxInfo) {
|
|
1250
|
+
this.model.markAsChecked(focusedNode, !focusedNode.checkboxInfo.checked);
|
|
1251
|
+
} else if (!this.props.multiSelect || (!event.ctrlKey && !event.metaKey && !event.shiftKey)) {
|
|
1236
1252
|
this.tapNode(focusedNode);
|
|
1237
1253
|
}
|
|
1238
1254
|
}
|
|
@@ -1497,7 +1513,10 @@ export class TreeWidget extends ReactWidget implements StatefulWidget {
|
|
|
1497
1513
|
return this.labelProvider.getLongName(node);
|
|
1498
1514
|
}
|
|
1499
1515
|
protected getDepthPadding(depth: number): number {
|
|
1500
|
-
|
|
1516
|
+
if (depth === 1) {
|
|
1517
|
+
return this.props.leftPadding;
|
|
1518
|
+
}
|
|
1519
|
+
return depth * this.treeIndent;
|
|
1501
1520
|
}
|
|
1502
1521
|
}
|
|
1503
1522
|
export namespace TreeWidget {
|
package/src/browser/tree/tree.ts
CHANGED
|
@@ -397,9 +397,10 @@ export class TreeImpl implements Tree {
|
|
|
397
397
|
|
|
398
398
|
protected async doMarkAsBusy(node: Mutable<TreeNode>, ms: number, token: CancellationToken): Promise<void> {
|
|
399
399
|
try {
|
|
400
|
+
token.onCancellationRequested(() => this.doResetBusy(node));
|
|
400
401
|
await timeout(ms, token);
|
|
402
|
+
if (token.isCancellationRequested) { return; }
|
|
401
403
|
this.doSetBusy(node);
|
|
402
|
-
token.onCancellationRequested(() => this.doResetBusy(node));
|
|
403
404
|
} catch {
|
|
404
405
|
/* no-op */
|
|
405
406
|
}
|
|
@@ -194,6 +194,31 @@ export class WidgetManager {
|
|
|
194
194
|
return widget;
|
|
195
195
|
}
|
|
196
196
|
|
|
197
|
+
/**
|
|
198
|
+
* Finds a widget that matches the given test predicate.
|
|
199
|
+
* @param factoryId The widget factory id.
|
|
200
|
+
* @param predicate The test predicate.
|
|
201
|
+
*
|
|
202
|
+
* @returns a promise resolving to the widget if available, else `undefined`.
|
|
203
|
+
*/
|
|
204
|
+
async findWidget<T extends Widget>(factoryId: string, predicate: (options?: any) => boolean): Promise<T | undefined> {
|
|
205
|
+
for (const [key, widget] of this.widgets.entries()) {
|
|
206
|
+
if (this.testPredicate(key, factoryId, predicate)) {
|
|
207
|
+
return widget as T;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
for (const [key, widget] of this.pendingWidgetPromises.entries()) {
|
|
211
|
+
if (this.testPredicate(key, factoryId, predicate)) {
|
|
212
|
+
return widget as T;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
protected testPredicate(key: string, factoryId: string, predicate: (options?: any) => boolean): boolean {
|
|
218
|
+
const constructionOptions = this.fromKey(key);
|
|
219
|
+
return constructionOptions.factoryId === factoryId && predicate(constructionOptions.options);
|
|
220
|
+
}
|
|
221
|
+
|
|
197
222
|
protected doGetWidget<T extends Widget>(key: string): MaybePromise<T> | undefined {
|
|
198
223
|
const pendingWidget = this.widgets.get(key) ?? this.pendingWidgetPromises.get(key);
|
|
199
224
|
if (pendingWidget) {
|
|
@@ -77,6 +77,7 @@ export class SelectComponent extends React.Component<SelectComponentProps, Selec
|
|
|
77
77
|
if (!list) {
|
|
78
78
|
list = document.createElement('div');
|
|
79
79
|
list.id = SELECT_COMPONENT_CONTAINER;
|
|
80
|
+
list.className = 'theia-select-component-container';
|
|
80
81
|
document.body.appendChild(list);
|
|
81
82
|
}
|
|
82
83
|
this.dropdownElement = list;
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2023 EclipseSource and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
import { ContainerModule } from 'inversify';
|
|
18
|
+
import { BackendStopwatch, CommandRegistry, Emitter, MeasurementOptions, OS } from '../common';
|
|
19
|
+
import { ApplicationInfo, ApplicationServer, ExtensionInfo } from '../common/application-protocol';
|
|
20
|
+
import { EnvVariable, EnvVariablesServer } from './../common/env-variables';
|
|
21
|
+
import { bindMessageService } from '../browser/frontend-application-bindings';
|
|
22
|
+
import { KeyStoreService } from '../common/key-store';
|
|
23
|
+
import { QuickPickService } from '../common/quick-pick-service';
|
|
24
|
+
import { QuickPickServiceImpl } from '../browser/quick-input';
|
|
25
|
+
import { BackendRequestService, RequestService } from '@theia/request';
|
|
26
|
+
import { ConnectionStatus, ConnectionStatusService } from '../browser/connection-status-service';
|
|
27
|
+
|
|
28
|
+
export { bindMessageService };
|
|
29
|
+
|
|
30
|
+
// is loaded directly after the regular frontend module
|
|
31
|
+
export const frontendOnlyApplicationModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
32
|
+
|
|
33
|
+
if (isBound(CommandRegistry)) {
|
|
34
|
+
rebind(CommandRegistry).toSelf().inSingletonScope();
|
|
35
|
+
} else {
|
|
36
|
+
bind(CommandRegistry).toSelf().inSingletonScope();
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
const stopwatch: BackendStopwatch = {
|
|
40
|
+
start: async (_name: string, _options?: MeasurementOptions | undefined): Promise<number> => -1,
|
|
41
|
+
stop: async (_measurement: number, _message: string, _messageArgs: unknown[]): Promise<void> => { }
|
|
42
|
+
};
|
|
43
|
+
if (isBound(BackendStopwatch)) {
|
|
44
|
+
rebind(BackendStopwatch).toConstantValue(stopwatch);
|
|
45
|
+
} else {
|
|
46
|
+
bind(BackendStopwatch).toConstantValue(stopwatch);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
if (isBound(CommandRegistry)) {
|
|
50
|
+
rebind(QuickPickService).to(QuickPickServiceImpl).inSingletonScope();
|
|
51
|
+
} else {
|
|
52
|
+
bind(QuickPickService).to(QuickPickServiceImpl).inSingletonScope();
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
const mockedApplicationServer: ApplicationServer = {
|
|
56
|
+
getExtensionsInfos: async (): Promise<ExtensionInfo[]> => [],
|
|
57
|
+
getApplicationInfo: async (): Promise<ApplicationInfo | undefined> => undefined,
|
|
58
|
+
getApplicationRoot: async (): Promise<string> => '',
|
|
59
|
+
getBackendOS: async (): Promise<OS.Type> => OS.Type.Linux
|
|
60
|
+
};
|
|
61
|
+
if (isBound(ApplicationServer)) {
|
|
62
|
+
rebind(ApplicationServer).toConstantValue(mockedApplicationServer);
|
|
63
|
+
} else {
|
|
64
|
+
bind(ApplicationServer).toConstantValue(mockedApplicationServer);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
const varServer: EnvVariablesServer = {
|
|
68
|
+
getExecPath: async (): Promise<string> => '',
|
|
69
|
+
getVariables: async (): Promise<EnvVariable[]> => [],
|
|
70
|
+
getValue: async (_key: string): Promise<EnvVariable | undefined> => undefined,
|
|
71
|
+
getConfigDirUri: async (): Promise<string> => '',
|
|
72
|
+
getHomeDirUri: async (): Promise<string> => '',
|
|
73
|
+
getDrives: async (): Promise<string[]> => []
|
|
74
|
+
};
|
|
75
|
+
if (isBound(EnvVariablesServer)) {
|
|
76
|
+
rebind(EnvVariablesServer).toConstantValue(varServer);
|
|
77
|
+
} else {
|
|
78
|
+
bind(EnvVariablesServer).toConstantValue(varServer);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
const keyStoreService: KeyStoreService = {
|
|
82
|
+
deletePassword: () => Promise.resolve(false),
|
|
83
|
+
findCredentials: () => Promise.resolve([]),
|
|
84
|
+
findPassword: () => Promise.resolve(undefined),
|
|
85
|
+
setPassword: () => Promise.resolve(),
|
|
86
|
+
getPassword: () => Promise.resolve(undefined)
|
|
87
|
+
};
|
|
88
|
+
if (isBound(KeyStoreService)) {
|
|
89
|
+
rebind<KeyStoreService>(KeyStoreService).toConstantValue(keyStoreService);
|
|
90
|
+
} else {
|
|
91
|
+
bind<KeyStoreService>(KeyStoreService).toConstantValue(keyStoreService);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
const requestService: RequestService = {
|
|
95
|
+
configure: () => Promise.resolve(),
|
|
96
|
+
request: () => Promise.reject(),
|
|
97
|
+
resolveProxy: () => Promise.resolve(undefined)
|
|
98
|
+
};
|
|
99
|
+
if (isBound(BackendRequestService)) {
|
|
100
|
+
rebind<RequestService>(BackendRequestService).toConstantValue(requestService);
|
|
101
|
+
} else {
|
|
102
|
+
bind<RequestService>(BackendRequestService).toConstantValue(requestService);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
const connectionStatusService: ConnectionStatusService = {
|
|
106
|
+
currentStatus: ConnectionStatus.ONLINE,
|
|
107
|
+
onStatusChange: new Emitter<ConnectionStatus>().event
|
|
108
|
+
};
|
|
109
|
+
if (isBound(ConnectionStatusService)) {
|
|
110
|
+
rebind<ConnectionStatusService>(ConnectionStatusService).toConstantValue(connectionStatusService);
|
|
111
|
+
} else {
|
|
112
|
+
bind<ConnectionStatusService>(ConnectionStatusService).toConstantValue(connectionStatusService);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
});
|