mirror of
https://github.com/microsoft/vscode.git
synced 2026-06-02 21:55:33 +01:00
Add experimental Continue Edit Session API command (#152375)
* Implement `vscode.experimental.editSession.continue` API command * Read `editSessionId` from protocol url query params Pass it down to `environmentService` for later access Read it from `environmentService` when attempting to apply edit session * Pass `editSessionId` to environmentService in web * Set and clear edit session ID * Add logging and encode ref in query parameters * Update test
This commit is contained in:
@@ -876,6 +876,13 @@ export class CodeApplication extends Disposable {
|
||||
// or if no window is open (macOS only)
|
||||
shouldOpenInNewWindow ||= isMacintosh && windowsMainService.getWindowCount() === 0;
|
||||
|
||||
// Pass along edit session id
|
||||
if (params.get('edit-session-id') !== null) {
|
||||
environmentService.editSessionId = params.get('edit-session-id') ?? undefined;
|
||||
params.delete('edit-session-id');
|
||||
uri = uri.with({ query: params.toString() });
|
||||
}
|
||||
|
||||
// Check for URIs to open in window
|
||||
const windowOpenableFromProtocolLink = app.getWindowOpenableFromProtocolLink(uri);
|
||||
logService.trace('app#handleURL: windowOpenableFromProtocolLink = ', windowOpenableFromProtocolLink);
|
||||
|
||||
Reference in New Issue
Block a user