@@ -16,6 +16,7 @@ import { URI } from 'vs/base/common/uri';
1616import { mapToSerializable } from 'vs/base/common/map' ;
1717import { IWorkbenchEnvironmentService } from 'vs/workbench/services/environment/common/environmentService' ;
1818import { IWorkspaceProvider , IWorkspace } from 'vs/workbench/services/host/browser/browserHostService' ;
19+ import { IProcessEnvironment } from 'vs/base/common/platform' ;
1920
2021class BrowserExtensionHostDebugService extends ExtensionHostDebugChannelClient implements IExtensionHostDebugService {
2122
@@ -44,11 +45,6 @@ class BrowserExtensionHostDebugService extends ExtensionHostDebugChannelClient i
4445 console . warn ( 'Extension Host Debugging not available due to missing workspace provider.' ) ;
4546 }
4647
47- this . registerListeners ( environmentService ) ;
48- }
49-
50- private registerListeners ( environmentService : IWorkbenchEnvironmentService ) : void {
51-
5248 // Reload window on reload request
5349 this . _register ( this . onReload ( event => {
5450 if ( environmentService . isExtensionDevelopment && environmentService . debugExtensionHost . debugId === event . sessionId ) {
@@ -64,7 +60,8 @@ class BrowserExtensionHostDebugService extends ExtensionHostDebugChannelClient i
6460 } ) ) ;
6561 }
6662
67- async openExtensionDevelopmentHostWindow ( args : string [ ] ) : Promise < void > {
63+ openExtensionDevelopmentHostWindow ( args : string [ ] , env : IProcessEnvironment ) : Promise < void > {
64+
6865 if ( ! this . workspaceProvider . payload ) {
6966 // TODO@Ben remove me once environment is adopted
7067 return this . openExtensionDevelopmentHostWindowLegacy ( args ) ;
@@ -101,13 +98,13 @@ class BrowserExtensionHostDebugService extends ExtensionHostDebugChannelClient i
10198 }
10299
103100 // Open debug window as new window. Pass ParsedArgs over.
104- this . workspaceProvider . open ( debugWorkspace , {
101+ return this . workspaceProvider . open ( debugWorkspace , {
105102 reuse : false , // debugging always requires a new window
106103 payload : mapToSerializable ( environment ) // mandatory properties to enable debugging
107104 } ) ;
108105 }
109106
110- private async openExtensionDevelopmentHostWindowLegacy ( args : string [ ] ) : Promise < void > {
107+ private openExtensionDevelopmentHostWindowLegacy ( args : string [ ] ) : Promise < void > {
111108 // we pass the "args" as query parameters of the URL
112109
113110 let newAddress = `${ document . location . origin } ${ document . location . pathname } ?` ;
0 commit comments