@@ -21,7 +21,7 @@ import { IFileService } from 'vs/platform/files/common/files';
2121import { IWorkspaceContextService , IWorkspaceFolder , WorkbenchState } from 'vs/platform/workspace/common/workspace' ;
2222import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation' ;
2323import { ICommandService } from 'vs/platform/commands/common/commands' ;
24- import { IDebugConfigurationProvider , ICompound , IDebugConfiguration , IConfig , IGlobalConfig , IConfigurationManager , ILaunch , IDebugAdapterDescriptorFactory , IDebugAdapter , ITerminalSettings , ITerminalLauncher , IDebugSession , IAdapterDescriptor , CONTEXT_DEBUG_CONFIGURATION_TYPE , IDebugAdapterFactory , IDebugService , IDebugHelperService } from 'vs/workbench/contrib/debug/common/debug' ;
24+ import { IDebugConfigurationProvider , ICompound , IDebugConfiguration , IConfig , IGlobalConfig , IConfigurationManager , ILaunch , IDebugAdapterDescriptorFactory , IDebugAdapter , ITerminalSettings , IDebugSession , IAdapterDescriptor , CONTEXT_DEBUG_CONFIGURATION_TYPE , IDebugAdapterFactory , IDebugService } from 'vs/workbench/contrib/debug/common/debug' ;
2525import { Debugger } from 'vs/workbench/contrib/debug/common/debugger' ;
2626import { IEditorService , ACTIVE_GROUP , SIDE_GROUP } from 'vs/workbench/services/editor/common/editorService' ;
2727import { isCodeEditor } from 'vs/editor/browser/editorBrowser' ;
@@ -52,7 +52,6 @@ export class ConfigurationManager implements IConfigurationManager {
5252 private configProviders : IDebugConfigurationProvider [ ] ;
5353 private adapterDescriptorFactories : IDebugAdapterDescriptorFactory [ ] ;
5454 private debugAdapterFactories = new Map < string , IDebugAdapterFactory > ( ) ;
55- private terminalLauncher : ITerminalLauncher ;
5655 private debugConfigurationTypeContext : IContextKey < string > ;
5756
5857 constructor (
@@ -66,8 +65,7 @@ export class ConfigurationManager implements IConfigurationManager {
6665 @IStorageService private readonly storageService : IStorageService ,
6766 @ILifecycleService lifecycleService : ILifecycleService ,
6867 @IExtensionService private readonly extensionService : IExtensionService ,
69- @IContextKeyService contextKeyService : IContextKeyService ,
70- @IDebugHelperService private readonly debugHelperService : IDebugHelperService
68+ @IContextKeyService contextKeyService : IContextKeyService
7169 ) {
7270 this . configProviders = [ ] ;
7371 this . adapterDescriptorFactories = [ ] ;
@@ -111,14 +109,11 @@ export class ConfigurationManager implements IConfigurationManager {
111109 }
112110
113111 runInTerminal ( debugType : string , args : DebugProtocol . RunInTerminalRequestArguments , config : ITerminalSettings ) : Promise < number | undefined > {
114- let tl : ITerminalLauncher | undefined = this . debugAdapterFactories . get ( debugType ) ;
115- if ( ! tl ) {
116- if ( ! this . terminalLauncher ) {
117- this . terminalLauncher = this . debugHelperService . createTerminalLauncher ( this . instantiationService ) ;
118- }
119- tl = this . terminalLauncher ;
112+ let tl = this . debugAdapterFactories . get ( debugType ) ;
113+ if ( tl ) {
114+ return tl . runInTerminal ( args , config ) ;
120115 }
121- return tl . runInTerminal ( args , config ) ;
116+ return Promise . resolve ( void 0 ) ;
122117 }
123118
124119 // debug adapter
0 commit comments