-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: implement debug service override
- Loading branch information
Loïc Mangeonjean
committed
Mar 22, 2023
1 parent
8b3a1d8
commit efbb861
Showing
7 changed files
with
52 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import '../polyfill' | ||
import '../vscode-services/missing-services' | ||
import { IEditorOverrideServices } from 'vs/editor/standalone/browser/standaloneServices' | ||
import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors' | ||
import { IRawLanguageExtensionPoint } from 'vs/workbench/services/language/common/languageService' | ||
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation' | ||
import { IDebugService } from 'vs/workbench/contrib/debug/common/debug' | ||
import { DebugService } from 'vs/workbench/contrib/debug/browser/debugService' | ||
import { LanguageFeaturesService } from 'vscode/vs/editor/common/services/languageFeaturesService' | ||
import { ILanguageFeaturesService } from 'vs/editor/common/services/languageFeatures' | ||
import { ConfigurationResolverService } from 'vs/workbench/services/configurationResolver/browser/configurationResolverService' | ||
import { IConfigurationResolverService } from 'vs/workbench/services/configurationResolver/common/configurationResolver' | ||
import { DebugToolBar } from 'vs/workbench/contrib/debug/browser/debugToolBar' | ||
import { DebugContentProvider } from 'vs/workbench/contrib/debug/common/debugContentProvider' | ||
import getLayoutServiceOverride from './layout' | ||
import { onServicesInitialized } from './tools' | ||
import 'vs/workbench/contrib/debug/browser/debug.contribution' | ||
|
||
function initialize (instantiationService: IInstantiationService) { | ||
setTimeout(() => { | ||
instantiationService.createInstance(DebugToolBar) | ||
instantiationService.createInstance(DebugContentProvider) | ||
}) | ||
} | ||
|
||
export default function getServiceOverride (): IEditorOverrideServices { | ||
onServicesInitialized(initialize) | ||
|
||
return { | ||
...getLayoutServiceOverride(), | ||
[ILanguageFeaturesService.toString()]: new SyncDescriptor(LanguageFeaturesService), // To restore inlineValuesProvider | ||
[IDebugService.toString()]: new SyncDescriptor(DebugService), | ||
[IConfigurationResolverService.toString()]: new SyncDescriptor(ConfigurationResolverService) | ||
} | ||
} | ||
|
||
export { | ||
IRawLanguageExtensionPoint | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters