@codingame/monaco-vscode-debug-service-override 1.83.1 → 1.83.3-next.0

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.
Files changed (48) hide show
  1. package/package.json +2 -2
  2. package/vscode/src/vs/workbench/contrib/debug/browser/baseDebugView.js +2 -2
  3. package/vscode/src/vs/workbench/contrib/debug/browser/breakpointEditorContribution.js +104 -139
  4. package/vscode/src/vs/workbench/contrib/debug/browser/breakpointWidget.js +5 -26
  5. package/vscode/src/vs/workbench/contrib/debug/browser/breakpointsView.js +61 -104
  6. package/vscode/src/vs/workbench/contrib/debug/browser/callStackEditorContribution.js +3 -9
  7. package/vscode/src/vs/workbench/contrib/debug/browser/callStackView.js +29 -51
  8. package/vscode/src/vs/workbench/contrib/debug/browser/debug.contribution.js +190 -203
  9. package/vscode/src/vs/workbench/contrib/debug/browser/debugActionViewItems.js +4 -4
  10. package/vscode/src/vs/workbench/contrib/debug/browser/debugAdapterManager.js +11 -31
  11. package/vscode/src/vs/workbench/contrib/debug/browser/debugCommands.js +32 -32
  12. package/vscode/src/vs/workbench/contrib/debug/browser/debugConfigurationManager.js +5 -5
  13. package/vscode/src/vs/workbench/contrib/debug/browser/debugConsoleQuickAccess.js +3 -3
  14. package/vscode/src/vs/workbench/contrib/debug/browser/debugEditorActions.js +21 -48
  15. package/vscode/src/vs/workbench/contrib/debug/browser/debugEditorContribution.js +2 -5
  16. package/vscode/src/vs/workbench/contrib/debug/browser/debugHover.js +3 -12
  17. package/vscode/src/vs/workbench/contrib/debug/browser/debugQuickAccess.js +11 -15
  18. package/vscode/src/vs/workbench/contrib/debug/browser/debugService.js +28 -80
  19. package/vscode/src/vs/workbench/contrib/debug/browser/debugSession.js +56 -68
  20. package/vscode/src/vs/workbench/contrib/debug/browser/debugSessionPicker.js +3 -8
  21. package/vscode/src/vs/workbench/contrib/debug/browser/debugStatus.js +3 -3
  22. package/vscode/src/vs/workbench/contrib/debug/browser/debugTaskRunner.js +17 -50
  23. package/vscode/src/vs/workbench/contrib/debug/browser/debugTitle.js +31 -0
  24. package/vscode/src/vs/workbench/contrib/debug/browser/debugToolBar.js +9 -4
  25. package/vscode/src/vs/workbench/contrib/debug/browser/debugViewlet.js +12 -4
  26. package/vscode/src/vs/workbench/contrib/debug/browser/disassemblyView.js +47 -51
  27. package/vscode/src/vs/workbench/contrib/debug/browser/exceptionWidget.js +13 -11
  28. package/vscode/src/vs/workbench/contrib/debug/browser/linkDetector.js +4 -4
  29. package/vscode/src/vs/workbench/contrib/debug/browser/loadedScriptsView.js +6 -25
  30. package/vscode/src/vs/workbench/contrib/debug/browser/rawDebugSession.js +9 -12
  31. package/vscode/src/vs/workbench/contrib/debug/browser/repl.js +15 -21
  32. package/vscode/src/vs/workbench/contrib/debug/browser/replViewer.js +6 -20
  33. package/vscode/src/vs/workbench/contrib/debug/browser/statusbarColorProvider.js +5 -17
  34. package/vscode/src/vs/workbench/contrib/debug/browser/variablesView.js +10 -18
  35. package/vscode/src/vs/workbench/contrib/debug/browser/watchExpressionsView.js +10 -13
  36. package/vscode/src/vs/workbench/contrib/debug/browser/welcomeView.js +70 -29
  37. package/vscode/src/vs/workbench/contrib/debug/common/debugContentProvider.js +6 -9
  38. package/vscode/src/vs/workbench/contrib/debug/common/debugLifecycle.js +3 -12
  39. package/vscode/src/vs/workbench/contrib/debug/common/debugModel.js +113 -148
  40. package/vscode/src/vs/workbench/contrib/debug/common/debugSchemas.js +41 -143
  41. package/vscode/src/vs/workbench/contrib/debug/common/debugSource.js +1 -1
  42. package/vscode/src/vs/workbench/contrib/debug/common/debugger.js +11 -36
  43. package/vscode/src/vs/workbench/contrib/debug/common/disassemblyViewInput.js +2 -2
  44. package/vscode/src/vs/workbench/contrib/debug/common/loadedScriptsPicker.js +1 -1
  45. package/vscode/src/vs/workbench/contrib/debug/common/replModel.js +1 -1
  46. package/vscode/src/vs/workbench/services/configurationResolver/browser/baseConfigurationResolverService.js +11 -16
  47. package/vscode/src/vs/workbench/services/configurationResolver/common/configurationResolverSchema.js +16 -49
  48. package/vscode/src/vs/workbench/services/configurationResolver/common/configurationResolverUtils.js +1 -4
@@ -3,7 +3,7 @@ import { DisposableStore, dispose } from 'monaco-editor/esm/vs/base/common/lifec
3
3
  import './media/debugViewlet.css.js';
4
4
  import * as nls from 'monaco-editor/esm/vs/nls.js';
5
5
  import { createActionViewItem } from 'monaco-editor/esm/vs/platform/actions/browser/menuEntryActionViewItem.js';
6
- import { registerAction2, Action2 } from 'monaco-editor/esm/vs/platform/actions/common/actions.js';
6
+ import { registerAction2, Action2, MenuRegistry, MenuId } from 'monaco-editor/esm/vs/platform/actions/common/actions.js';
7
7
  import { IConfigurationService } from 'monaco-editor/esm/vs/platform/configuration/common/configuration.js';
8
8
  import { ContextKeyExpr, IContextKeyService } from 'monaco-editor/esm/vs/platform/contextkey/common/contextkey.js';
9
9
  import { IContextMenuService, IContextViewService } from 'monaco-editor/esm/vs/platform/contextview/browser/contextView.js';
@@ -16,10 +16,10 @@ import { IWorkspaceContextService } from 'monaco-editor/esm/vs/platform/workspac
16
16
  import { ViewsSubMenu, ViewPaneContainer } from 'vscode/vscode/vs/workbench/browser/parts/views/viewPaneContainer';
17
17
  import { IViewsService, IViewDescriptorService } from 'vscode/vscode/vs/workbench/common/views';
18
18
  import { StartDebugActionViewItem, FocusSessionActionViewItem } from './debugActionViewItems.js';
19
- import { DEBUG_START_COMMAND_ID, FOCUS_SESSION_ID, STOP_ID, DISCONNECT_ID } from './debugCommands.js';
19
+ import { SELECT_AND_START_ID, DEBUG_START_COMMAND_ID, FOCUS_SESSION_ID, STOP_ID, DISCONNECT_ID } from './debugCommands.js';
20
20
  import { createDisconnectMenuItemAction } from './debugToolBar.js';
21
21
  import { WelcomeView } from './welcomeView.js';
22
- import { REPL_VIEW_ID, VIEWLET_ID, CONTEXT_DEBUG_UX_KEY, BREAKPOINTS_VIEW_ID, IDebugService } from 'vscode/vscode/vs/workbench/contrib/debug/common/debug';
22
+ import { REPL_VIEW_ID, VIEWLET_ID, CONTEXT_DEBUG_STATE, CONTEXT_DEBUG_UX_KEY, BREAKPOINTS_VIEW_ID, IDebugService } from 'vscode/vscode/vs/workbench/contrib/debug/common/debug';
23
23
  import { IExtensionService } from 'vscode/vscode/vs/workbench/services/extensions/common/extensions';
24
24
  import { IWorkbenchLayoutService } from 'vscode/vscode/vs/workbench/services/layout/browser/layoutService';
25
25
 
@@ -144,7 +144,7 @@ registerAction2(class extends Action2 {
144
144
  constructor() {
145
145
  super({
146
146
  id: 'debug.toggleReplIgnoreFocus',
147
- title: ( nls.localize('debugPanel', "Debug Console")),
147
+ title: nls.localizeWithPath('vs/workbench/contrib/debug/browser/debugViewlet', 'debugPanel', "Debug Console"),
148
148
  toggled: ( ContextKeyExpr.has(`view.${REPL_VIEW_ID}.visible`)),
149
149
  menu: [{
150
150
  id: ViewsSubMenu,
@@ -164,5 +164,13 @@ registerAction2(class extends Action2 {
164
164
  }
165
165
  }
166
166
  });
167
+ ( MenuRegistry.appendMenuItem(MenuId.ViewContainerTitle, {
168
+ when: ( ContextKeyExpr.and(( ContextKeyExpr.equals('viewContainer', VIEWLET_ID)), ( CONTEXT_DEBUG_STATE.notEqualsTo('inactive')), ( ContextKeyExpr.equals('config.debug.toolBarLocation', 'docked')))),
169
+ order: 10,
170
+ command: {
171
+ id: SELECT_AND_START_ID,
172
+ title: nls.localizeWithPath('vs/workbench/contrib/debug/browser/debugViewlet', 'startAdditionalSession', "Start Additional Session"),
173
+ }
174
+ }));
167
175
 
168
176
  export { DebugViewPaneContainer };
@@ -12,7 +12,7 @@ import { BareFontInfo } from 'monaco-editor/esm/vs/editor/common/config/fontInfo
12
12
  import { Range } from 'monaco-editor/esm/vs/editor/common/core/range.js';
13
13
  import { StringBuilder } from 'monaco-editor/esm/vs/editor/common/core/stringBuilder.js';
14
14
  import { ITextModelService } from 'monaco-editor/esm/vs/editor/common/services/resolverService.js';
15
- import { localize } from 'monaco-editor/esm/vs/nls.js';
15
+ import { localizeWithPath } from 'monaco-editor/esm/vs/nls.js';
16
16
  import { IConfigurationService } from 'monaco-editor/esm/vs/platform/configuration/common/configuration.js';
17
17
  import { IContextKeyService } from 'monaco-editor/esm/vs/platform/contextkey/common/contextkey.js';
18
18
  import { IInstantiationService } from 'monaco-editor/esm/vs/platform/instantiation/common/instantiation.js';
@@ -43,7 +43,7 @@ const disassemblyNotAvailable = {
43
43
  address: 0n,
44
44
  instruction: {
45
45
  address: '-1',
46
- instruction: ( (localize('instructionNotAvailable', "Disassembly not available.")))
46
+ instruction: localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', 'instructionNotAvailable', "Disassembly not available.")
47
47
  },
48
48
  };
49
49
  let DisassemblyView = class DisassemblyView extends EditorPane {
@@ -57,9 +57,9 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
57
57
  this._instructionBpList = [];
58
58
  this._enableSourceCodeRender = true;
59
59
  this._loadingLock = false;
60
- this._referenceToMemoryAddress = ( (new Map()));
60
+ this._referenceToMemoryAddress = ( new Map());
61
61
  this._disassembledInstructions = undefined;
62
- this._onDidChangeStackFrame = this._register(( (new Emitter({ leakWarningThreshold: 1000 }))));
62
+ this._onDidChangeStackFrame = this._register(( new Emitter({ leakWarningThreshold: 1000 })));
63
63
  this._previousDebuggingState = _debugService.state;
64
64
  this._fontInfo = BareFontInfo.createFromRawSettings(_configurationService.getValue('editor'), PixelRatio.value);
65
65
  this._register(_configurationService.onDidChangeConfiguration(e => {
@@ -79,14 +79,12 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
79
79
  }
80
80
  get fontInfo() { return this._fontInfo; }
81
81
  get currentInstructionAddresses() {
82
- return (
83
- (( (( (( (this._debugService.getModel().getSessions(false).
84
- map(session => session.getAllThreads()))).
85
- reduce((prev, curr) => prev.concat(curr), []).
86
- map(thread => thread.getTopStackFrame()))).
87
- map(frame => frame?.instructionPointerReference))).
88
- map(ref => ref ? this.getReferenceAddress(ref) : undefined))
89
- );
82
+ return ( ( ( ( this._debugService.getModel().getSessions(false).
83
+ map(session => session.getAllThreads())).
84
+ reduce((prev, curr) => prev.concat(curr), []).
85
+ map(thread => thread.getTopStackFrame())).
86
+ map(frame => frame?.instructionPointerReference)).
87
+ map(ref => ref ? this.getReferenceAddress(ref) : undefined));
90
88
  }
91
89
  get focusedCurrentInstructionReference() {
92
90
  return this._debugService.getViewModel().focusedStackFrame?.thread.getTopStackFrame()?.instructionPointerReference;
@@ -148,7 +146,7 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
148
146
  project(row) { return row; }
149
147
  },
150
148
  {
151
- label: ( (localize('disassemblyTableColumnLabel', "instructions"))),
149
+ label: localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', 'disassemblyTableColumnLabel', "instructions"),
152
150
  tooltip: '',
153
151
  weight: 0.3,
154
152
  templateId: InstructionRenderer.TEMPLATE_ID,
@@ -166,7 +164,7 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
166
164
  multipleSelectionSupport: false,
167
165
  setRowLineHeight: false,
168
166
  openOnSingleClick: false,
169
- accessibilityProvider: ( (new AccessibilityProvider())),
167
+ accessibilityProvider: ( new AccessibilityProvider()),
170
168
  mouseSupport: false
171
169
  }));
172
170
  if (this.focusedInstructionReference) {
@@ -298,7 +296,7 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
298
296
  return 0;
299
297
  }
300
298
  async primeMemoryReference(instructionReference) {
301
- if (( (this._referenceToMemoryAddress.has(instructionReference)))) {
299
+ if (( this._referenceToMemoryAddress.has(instructionReference))) {
302
300
  return true;
303
301
  }
304
302
  const s = await this.debugSession?.disassemble(instructionReference, 0, 0, 1);
@@ -316,7 +314,7 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
316
314
  async loadDisassembledInstructions(instructionReference, offset, instructionOffset, instructionCount) {
317
315
  const session = this.debugSession;
318
316
  const resultEntries = await session?.disassemble(instructionReference, offset, instructionOffset, instructionCount);
319
- if (!( (this._referenceToMemoryAddress.has(instructionReference))) && instructionOffset !== 0) {
317
+ if (!( this._referenceToMemoryAddress.has(instructionReference)) && instructionOffset !== 0) {
320
318
  await this.loadDisassembledInstructions(instructionReference, 0, 0, DisassemblyView_1.NUM_INSTRUCTIONS_TO_LOAD);
321
319
  }
322
320
  if (session && resultEntries && this._disassembledInstructions) {
@@ -369,7 +367,7 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
369
367
  return 0;
370
368
  }
371
369
  const refBaseAddress = this._referenceToMemoryAddress.get(instructionReference);
372
- const bps = ( (this._instructionBpList.map(p => {
370
+ const bps = ( this._instructionBpList.map(p => {
373
371
  const base = this._referenceToMemoryAddress.get(p.instructionReference);
374
372
  if (!base) {
375
373
  return undefined;
@@ -378,7 +376,7 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
378
376
  enabled: p.enabled,
379
377
  address: base + BigInt(p.offset || 0),
380
378
  };
381
- })));
379
+ }));
382
380
  if (refBaseAddress !== undefined) {
383
381
  for (const entry of newEntries) {
384
382
  const bp = bps.find(p => p?.address === entry.address);
@@ -459,14 +457,14 @@ let DisassemblyView = class DisassemblyView extends EditorPane {
459
457
  this._disassembledInstructions?.splice(0, this._disassembledInstructions.length, [disassemblyNotAvailable]);
460
458
  }
461
459
  };
462
- DisassemblyView = DisassemblyView_1 = ( (__decorate([
463
- ( (__param(0, ITelemetryService))),
464
- ( (__param(1, IThemeService))),
465
- ( (__param(2, IStorageService))),
466
- ( (__param(3, IConfigurationService))),
467
- ( (__param(4, IInstantiationService))),
468
- ( (__param(5, IDebugService)))
469
- ], DisassemblyView)));
460
+ DisassemblyView = DisassemblyView_1 = ( __decorate([
461
+ ( __param(0, ITelemetryService)),
462
+ ( __param(1, IThemeService)),
463
+ ( __param(2, IStorageService)),
464
+ ( __param(3, IConfigurationService)),
465
+ ( __param(4, IInstantiationService)),
466
+ ( __param(5, IDebugService))
467
+ ], DisassemblyView));
470
468
  let BreakpointRenderer = class BreakpointRenderer {
471
469
  static { BreakpointRenderer_1 = this; }
472
470
  static { this.TEMPLATE_ID = 'breakpoint'; }
@@ -553,9 +551,9 @@ let BreakpointRenderer = class BreakpointRenderer {
553
551
  }
554
552
  }
555
553
  };
556
- BreakpointRenderer = BreakpointRenderer_1 = ( (__decorate([
557
- ( (__param(1, IDebugService)))
558
- ], BreakpointRenderer)));
554
+ BreakpointRenderer = BreakpointRenderer_1 = ( __decorate([
555
+ ( __param(1, IDebugService))
556
+ ], BreakpointRenderer));
559
557
  let InstructionRenderer = class InstructionRenderer extends Disposable {
560
558
  static { InstructionRenderer_1 = this; }
561
559
  static { this.TEMPLATE_ID = 'instruction'; }
@@ -596,12 +594,12 @@ let InstructionRenderer = class InstructionRenderer extends Disposable {
596
594
  templateData.currentElement.element = element;
597
595
  const instruction = element.instruction;
598
596
  templateData.sourcecode.innerText = '';
599
- const sb = ( (new StringBuilder(1000)));
597
+ const sb = ( new StringBuilder(1000));
600
598
  if (this._disassemblyView.isSourceCodeRender && element.showSourceLocation && instruction.location?.path && instruction.line !== undefined) {
601
599
  const sourceURI = this.getUriFromSource(instruction);
602
600
  if (sourceURI) {
603
601
  let textModel = undefined;
604
- const sourceSB = ( (new StringBuilder(10000)));
602
+ const sourceSB = ( new StringBuilder(10000));
605
603
  const ref = await this.textModelService.createModelReference(sourceURI);
606
604
  textModel = ref.object.textEditorModel;
607
605
  templateData.cellDisposable.push(ref);
@@ -680,7 +678,7 @@ let InstructionRenderer = class InstructionRenderer extends Disposable {
680
678
  };
681
679
  this.editorService.openEditor({
682
680
  resource: sourceURI,
683
- description: ( (localize('editorOpenedFromDisassemblyDescription', "from disassembly"))),
681
+ description: localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', 'editorOpenedFromDisassemblyDescription', "from disassembly"),
684
682
  options: {
685
683
  preserveFocus: false,
686
684
  selection: selection,
@@ -694,7 +692,7 @@ let InstructionRenderer = class InstructionRenderer extends Disposable {
694
692
  getUriFromSource(instruction) {
695
693
  const path = instruction.location.path;
696
694
  if (path && isUri(path)) {
697
- return this.uriService.asCanonicalUri(( (URI.parse(path))));
695
+ return this.uriService.asCanonicalUri(( URI.parse(path)));
698
696
  }
699
697
  if (path && isAbsolute(path)) {
700
698
  return this.uriService.asCanonicalUri(URI.file(path));
@@ -706,29 +704,27 @@ let InstructionRenderer = class InstructionRenderer extends Disposable {
706
704
  element.style.whiteSpace = 'pre';
707
705
  }
708
706
  };
709
- InstructionRenderer = InstructionRenderer_1 = ( (__decorate([
710
- ( (__param(1, IThemeService))),
711
- ( (__param(2, IEditorService))),
712
- ( (__param(3, ITextModelService))),
713
- ( (__param(4, IUriIdentityService))),
714
- ( (__param(5, ILogService)))
715
- ], InstructionRenderer)));
707
+ InstructionRenderer = InstructionRenderer_1 = ( __decorate([
708
+ ( __param(1, IThemeService)),
709
+ ( __param(2, IEditorService)),
710
+ ( __param(3, ITextModelService)),
711
+ ( __param(4, IUriIdentityService)),
712
+ ( __param(5, ILogService))
713
+ ], InstructionRenderer));
716
714
  class AccessibilityProvider {
717
715
  getWidgetAriaLabel() {
718
- return (
719
- (localize('disassemblyView', "Disassembly View"))
720
- );
716
+ return localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', 'disassemblyView', "Disassembly View");
721
717
  }
722
718
  getAriaLabel(element) {
723
719
  let label = '';
724
720
  const instruction = element.instruction;
725
721
  if (instruction.address !== '-1') {
726
- label += `${( ( localize('instructionAddress', "Address")))}: ${instruction.address}`;
722
+ label += `${localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', 'instructionAddress', "Address")}: ${instruction.address}`;
727
723
  }
728
724
  if (instruction.instructionBytes) {
729
- label += `, ${( ( localize('instructionBytes', "Bytes")))}: ${instruction.instructionBytes}`;
725
+ label += `, ${localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', 'instructionBytes', "Bytes")}: ${instruction.instructionBytes}`;
730
726
  }
731
- label += `, ${( ( localize(`instructionText`, "Instruction")))}: ${instruction.instruction}`;
727
+ label += `, ${localizeWithPath('vs/workbench/contrib/debug/browser/disassemblyView', `instructionText`, "Instruction")}: ${instruction.instruction}`;
732
728
  return label;
733
729
  }
734
730
  }
@@ -762,10 +758,10 @@ let DisassemblyViewContribution = class DisassemblyViewContribution {
762
758
  this._onDidChangeModelLanguage?.dispose();
763
759
  }
764
760
  };
765
- DisassemblyViewContribution = ( (__decorate([
766
- ( (__param(0, IEditorService))),
767
- ( (__param(1, IDebugService))),
768
- ( (__param(2, IContextKeyService)))
769
- ], DisassemblyViewContribution)));
761
+ DisassemblyViewContribution = ( __decorate([
762
+ ( __param(0, IEditorService)),
763
+ ( __param(1, IDebugService)),
764
+ ( __param(2, IContextKeyService))
765
+ ], DisassemblyViewContribution));
770
766
 
771
767
  export { DisassemblyView, DisassemblyViewContribution };
@@ -15,8 +15,8 @@ import { Action } from 'monaco-editor/esm/vs/base/common/actions.js';
15
15
  import { widgetClose } from 'monaco-editor/esm/vs/platform/theme/common/iconRegistry.js';
16
16
 
17
17
  const $ = dom.$;
18
- const debugExceptionWidgetBorder = registerColor('debugExceptionWidget.border', { dark: '#a31515', light: '#a31515', hcDark: '#a31515', hcLight: '#a31515' }, ( nls.localize('debugExceptionWidgetBorder', 'Exception widget border color.')));
19
- const debugExceptionWidgetBackground = registerColor('debugExceptionWidget.background', { dark: '#420b0d', light: '#f1dfde', hcDark: '#420b0d', hcLight: '#f1dfde' }, ( nls.localize('debugExceptionWidgetBackground', 'Exception widget background color.')));
18
+ const debugExceptionWidgetBorder = registerColor('debugExceptionWidget.border', { dark: '#a31515', light: '#a31515', hcDark: '#a31515', hcLight: '#a31515' }, nls.localizeWithPath('vs/workbench/contrib/debug/browser/exceptionWidget', 'debugExceptionWidgetBorder', 'Exception widget border color.'));
19
+ const debugExceptionWidgetBackground = registerColor('debugExceptionWidget.background', { dark: '#420b0d', light: '#f1dfde', hcDark: '#420b0d', hcLight: '#f1dfde' }, nls.localizeWithPath('vs/workbench/contrib/debug/browser/exceptionWidget', 'debugExceptionWidgetBackground', 'Exception widget background color.'));
20
20
  let ExceptionWidget = class ExceptionWidget extends ZoneWidget {
21
21
  constructor(editor, exceptionInfo, debugSession, themeService, instantiationService) {
22
22
  super(editor, { showFrame: true, showArrow: true, isAccessible: true, frameWidth: 1, className: 'exception-widget-container' });
@@ -55,17 +55,19 @@ let ExceptionWidget = class ExceptionWidget extends ZoneWidget {
55
55
  dom.append(title, label);
56
56
  const actions = $('.actions');
57
57
  dom.append(title, actions);
58
- label.textContent = this.exceptionInfo.id ? ( nls.localize(
59
- 'exceptionThrownWithId',
60
- 'Exception has occurred: {0}',
61
- this.exceptionInfo.id
62
- )) : ( nls.localize('exceptionThrown', 'Exception has occurred.'));
58
+ label.textContent = this.exceptionInfo.id ? nls.localizeWithPath('vs/workbench/contrib/debug/browser/exceptionWidget', 'exceptionThrownWithId', 'Exception has occurred: {0}', this.exceptionInfo.id) : nls.localizeWithPath('vs/workbench/contrib/debug/browser/exceptionWidget', 'exceptionThrown', 'Exception has occurred.');
63
59
  let ariaLabel = label.textContent;
64
60
  const actionBar = ( new ActionBar(actions));
65
- actionBar.push(( new Action('editor.closeExceptionWidget', ( nls.localize('close', "Close")), ThemeIcon.asClassName(widgetClose), true, async () => {
66
- const contribution = this.editor.getContribution(EDITOR_CONTRIBUTION_ID);
67
- contribution?.closeExceptionWidget();
68
- })), { label: false, icon: true });
61
+ actionBar.push(( new Action(
62
+ 'editor.closeExceptionWidget',
63
+ nls.localizeWithPath('vs/workbench/contrib/debug/browser/exceptionWidget', 'close', "Close"),
64
+ ThemeIcon.asClassName(widgetClose),
65
+ true,
66
+ async () => {
67
+ const contribution = this.editor.getContribution(EDITOR_CONTRIBUTION_ID);
68
+ contribution?.closeExceptionWidget();
69
+ }
70
+ )), { label: false, icon: true });
69
71
  dom.append(container, title);
70
72
  if (this.exceptionInfo.description) {
71
73
  const description = $('.description');
@@ -9,7 +9,7 @@ import { IEditorService } from 'vscode/vscode/vs/workbench/services/editor/commo
9
9
  import { IWorkbenchEnvironmentService } from 'vscode/vscode/vs/workbench/services/environment/common/environmentService';
10
10
  import { IPathService } from 'vscode/vscode/vs/workbench/services/path/common/pathService';
11
11
  import { StandardKeyboardEvent } from 'monaco-editor/esm/vs/base/browser/keyboardEvent.js';
12
- import { localize } from 'monaco-editor/esm/vs/nls.js';
12
+ import { localizeWithPath } from 'monaco-editor/esm/vs/nls.js';
13
13
  import { ITunnelService } from 'vscode/vscode/vs/platform/tunnel/common/tunnel';
14
14
  import { IConfigurationService } from 'monaco-editor/esm/vs/platform/configuration/common/configuration.js';
15
15
 
@@ -153,10 +153,10 @@ let LinkDetector = class LinkDetector {
153
153
  }
154
154
  decorateLink(link, uri, fulltext, onClick) {
155
155
  link.classList.add('link');
156
- const followLink = this.tunnelService.canTunnel(uri) ? ( localize('followForwardedLink', "follow link using forwarded port")) : ( localize('followLink', "follow link"));
156
+ const followLink = this.tunnelService.canTunnel(uri) ? localizeWithPath('vs/workbench/contrib/debug/browser/linkDetector', 'followForwardedLink', "follow link using forwarded port") : localizeWithPath('vs/workbench/contrib/debug/browser/linkDetector', 'followLink', "follow link");
157
157
  link.title = fulltext
158
- ? (platform.isMacintosh ? ( localize('fileLinkWithPathMac', "Cmd + click to {0}\n{1}", followLink, fulltext)) : ( localize('fileLinkWithPath', "Ctrl + click to {0}\n{1}", followLink, fulltext)))
159
- : (platform.isMacintosh ? ( localize('fileLinkMac', "Cmd + click to {0}", followLink)) : ( localize('fileLink', "Ctrl + click to {0}", followLink)));
158
+ ? (platform.isMacintosh ? localizeWithPath('vs/workbench/contrib/debug/browser/linkDetector', 'fileLinkWithPathMac', "Cmd + click to {0}\n{1}", followLink, fulltext) : localizeWithPath('vs/workbench/contrib/debug/browser/linkDetector', 'fileLinkWithPath', "Ctrl + click to {0}\n{1}", followLink, fulltext))
159
+ : (platform.isMacintosh ? localizeWithPath('vs/workbench/contrib/debug/browser/linkDetector', 'fileLinkMac', "Cmd + click to {0}", followLink) : localizeWithPath('vs/workbench/contrib/debug/browser/linkDetector', 'fileLink', "Ctrl + click to {0}", followLink));
160
160
  link.onmousemove = (event) => { link.classList.toggle('pointer', platform.isMacintosh ? event.metaKey : event.ctrlKey); };
161
161
  link.onmouseleave = () => link.classList.remove('pointer');
162
162
  link.onclick = (event) => {
@@ -551,7 +551,7 @@ class LoadedScriptsRenderer {
551
551
  options.fileKind = FileKind.ROOT_FOLDER;
552
552
  }
553
553
  else if (element instanceof SessionTreeItem) {
554
- options.title = ( nls.localize('loadedScriptsSession', "Debug Session"));
554
+ options.title = nls.localizeWithPath('vs/workbench/contrib/debug/browser/loadedScriptsView', 'loadedScriptsSession', "Debug Session");
555
555
  options.hideIcon = true;
556
556
  }
557
557
  else if (element instanceof BaseTreeItem) {
@@ -573,39 +573,20 @@ class LoadedScriptsRenderer {
573
573
  }
574
574
  class LoadedSciptsAccessibilityProvider {
575
575
  getWidgetAriaLabel() {
576
- return ( nls.localize(
577
- { comment: ['Debug is a noun in this context, not a verb.'], key: 'loadedScriptsAriaLabel' },
578
- "Debug Loaded Scripts"
579
- ));
576
+ return nls.localizeWithPath('vs/workbench/contrib/debug/browser/loadedScriptsView', { comment: ['Debug is a noun in this context, not a verb.'], key: 'loadedScriptsAriaLabel' }, "Debug Loaded Scripts");
580
577
  }
581
578
  getAriaLabel(element) {
582
579
  if (element instanceof RootFolderTreeItem) {
583
- return ( nls.localize(
584
- 'loadedScriptsRootFolderAriaLabel',
585
- "Workspace folder {0}, loaded script, debug",
586
- element.getLabel()
587
- ));
580
+ return nls.localizeWithPath('vs/workbench/contrib/debug/browser/loadedScriptsView', 'loadedScriptsRootFolderAriaLabel', "Workspace folder {0}, loaded script, debug", element.getLabel());
588
581
  }
589
582
  if (element instanceof SessionTreeItem) {
590
- return ( nls.localize(
591
- 'loadedScriptsSessionAriaLabel',
592
- "Session {0}, loaded script, debug",
593
- element.getLabel()
594
- ));
583
+ return nls.localizeWithPath('vs/workbench/contrib/debug/browser/loadedScriptsView', 'loadedScriptsSessionAriaLabel', "Session {0}, loaded script, debug", element.getLabel());
595
584
  }
596
585
  if (element.hasChildren()) {
597
- return ( nls.localize(
598
- 'loadedScriptsFolderAriaLabel',
599
- "Folder {0}, loaded script, debug",
600
- element.getLabel()
601
- ));
586
+ return nls.localizeWithPath('vs/workbench/contrib/debug/browser/loadedScriptsView', 'loadedScriptsFolderAriaLabel', "Folder {0}, loaded script, debug", element.getLabel());
602
587
  }
603
588
  else {
604
- return ( nls.localize(
605
- 'loadedScriptsSourceAriaLabel',
606
- "{0}, loaded script, debug",
607
- element.getLabel()
608
- ));
589
+ return nls.localizeWithPath('vs/workbench/contrib/debug/browser/loadedScriptsView', 'loadedScriptsSourceAriaLabel', "{0}, loaded script, debug", element.getLabel());
609
590
  }
610
591
  }
611
592
  }
@@ -192,7 +192,9 @@ let RawDebugSession = class RawDebugSession {
192
192
  }
193
193
  async start() {
194
194
  if (!this.debugAdapter) {
195
- return Promise.reject(( new Error(( nls.localize('noDebugAdapterStart', "No debug adapter, can not start debug session.")))));
195
+ return Promise.reject(( new Error(
196
+ nls.localizeWithPath('vs/workbench/contrib/debug/browser/rawDebugSession', 'noDebugAdapterStart', "No debug adapter, can not start debug session.")
197
+ )));
196
198
  }
197
199
  await this.debugAdapter.startSession();
198
200
  this.startTime = ( new Date()).getTime();
@@ -512,11 +514,8 @@ let RawDebugSession = class RawDebugSession {
512
514
  if (!result.success) {
513
515
  const { confirmed } = await this.dialogSerivce.confirm({
514
516
  type: Severity.Warning,
515
- message: ( nls.localize(
516
- 'canNotStart',
517
- "The debugger needs to open a new tab or window for the debuggee but the browser prevented this. You must give permission to continue."
518
- )),
519
- primaryButton: ( nls.localize({ key: 'continue', comment: ['&& denotes a mnemonic'] }, "&&Continue"))
517
+ message: nls.localizeWithPath('vs/workbench/contrib/debug/browser/rawDebugSession', 'canNotStart', "The debugger needs to open a new tab or window for the debuggee but the browser prevented this. You must give permission to continue."),
518
+ primaryButton: nls.localizeWithPath('vs/workbench/contrib/debug/browser/rawDebugSession', { key: 'continue', comment: ['&& denotes a mnemonic'] }, "&&Continue")
520
519
  });
521
520
  if (confirmed) {
522
521
  result = await this.launchVsCode(request.arguments);
@@ -616,11 +615,9 @@ let RawDebugSession = class RawDebugSession {
616
615
  completeDispatch(undefined);
617
616
  }
618
617
  else {
619
- errorDispatch(( new Error(( nls.localize(
620
- 'noDebugAdapter',
621
- "No debugger available found. Can not send '{0}'.",
622
- command
623
- )))));
618
+ errorDispatch(( new Error(
619
+ nls.localizeWithPath('vs/workbench/contrib/debug/browser/rawDebugSession', 'noDebugAdapter', "No debugger available found. Can not send '{0}'.", command)
620
+ )));
624
621
  }
625
622
  return;
626
623
  }
@@ -653,7 +650,7 @@ let RawDebugSession = class RawDebugSession {
653
650
  const userMessage = error ? formatPII(error.format, false, error.variables) : errorMessage;
654
651
  const url = error?.url;
655
652
  if (error && url) {
656
- const label = error.urlLabel ? error.urlLabel : ( nls.localize('moreInfo', "More Info"));
653
+ const label = error.urlLabel ? error.urlLabel : nls.localizeWithPath('vs/workbench/contrib/debug/browser/rawDebugSession', 'moreInfo', "More Info");
657
654
  const uri = ( URI.parse(url));
658
655
  const actionId = uri.scheme === Schemas.command ? 'debug.moreInfo.command' : 'debug.moreInfo';
659
656
  return createErrorWithActions(userMessage, [toAction({ id: actionId, label, run: () => this.openerService.open(uri, { allowCommands: true }) })]);
@@ -23,7 +23,7 @@ import { ILanguageFeaturesService } from 'monaco-editor/esm/vs/editor/common/ser
23
23
  import { IModelService } from 'monaco-editor/esm/vs/editor/common/services/model.js';
24
24
  import { ITextResourcePropertiesService } from 'monaco-editor/esm/vs/editor/common/services/textResourceConfiguration.js';
25
25
  import { SuggestController } from 'monaco-editor/esm/vs/editor/contrib/suggest/browser/suggestController.js';
26
- import { localize } from 'monaco-editor/esm/vs/nls.js';
26
+ import { localizeWithPath } from 'monaco-editor/esm/vs/nls.js';
27
27
  import { createAndFillInContextMenuActions } from 'monaco-editor/esm/vs/platform/actions/browser/menuEntryActionViewItem.js';
28
28
  import { MenuId, registerAction2, Action2, IMenuService } from 'monaco-editor/esm/vs/platform/actions/common/actions.js';
29
29
  import { IClipboardService } from 'monaco-editor/esm/vs/platform/clipboard/common/clipboardService.js';
@@ -75,10 +75,7 @@ let Repl = class Repl extends FilterViewPane {
75
75
  super({
76
76
  ...options,
77
77
  filterOptions: {
78
- placeholder: ( (localize(
79
- { key: 'workbench.debug.filter.placeholder', comment: ['Text in the brackets after e.g. is not localizable'] },
80
- "Filter (e.g. text, !exclude)"
81
- ))),
78
+ placeholder: localizeWithPath('vs/workbench/contrib/debug/browser/repl', { key: 'workbench.debug.filter.placeholder', comment: ['Text in the brackets after e.g. is not localizable'] }, "Filter (e.g. text, !exclude)"),
82
79
  text: filterText,
83
80
  history: JSON.parse(storageService.get(FILTER_HISTORY_STORAGE_KEY, 1 , '[]')),
84
81
  }
@@ -448,7 +445,7 @@ let Repl = class Repl extends FilterViewPane {
448
445
  await autoExpandElements(session.getReplElements());
449
446
  }
450
447
  const { total, filtered } = this.getFilterStats();
451
- this.filterWidget.updateBadge(total === filtered || total === 0 ? undefined : ( (localize('showing filtered repl lines', "Showing {0} of {1}", filtered, total))));
448
+ this.filterWidget.updateBadge(total === filtered || total === 0 ? undefined : localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'showing filtered repl lines', "Showing {0} of {1}", filtered, total));
452
449
  }, Repl_1.REFRESH_DELAY))
453
450
  );
454
451
  }
@@ -548,7 +545,7 @@ let Repl = class Repl extends FilterViewPane {
548
545
  options.suggest = { showStatusBar: true };
549
546
  const config = this.configurationService.getValue('debug');
550
547
  options.acceptSuggestionOnEnter = config.console.acceptSuggestionOnEnter === 'on' ? 'on' : 'off';
551
- options.ariaLabel = ( (localize('debugConsole', "Debug Console")));
548
+ options.ariaLabel = localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'debugConsole', "Debug Console");
552
549
  this.replInput = this.scopedInstantiationService.createInstance(CodeEditorWidget, this.replInputContainer, options, getSimpleCodeEditorWidgetOptions());
553
550
  this._register(this.replInput.onDidChangeModelContent(() => {
554
551
  const model = this.replInput.getModel();
@@ -599,7 +596,7 @@ let Repl = class Repl extends FilterViewPane {
599
596
  },
600
597
  renderOptions: {
601
598
  after: {
602
- contentText: ( (localize('startDebugFirst', "Please start a debug session to evaluate expressions"))),
599
+ contentText: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'startDebugFirst', "Please start a debug session to evaluate expressions"),
603
600
  color: transparentForeground ? ( (transparentForeground.toString())) : undefined
604
601
  }
605
602
  }
@@ -711,10 +708,7 @@ class AcceptReplInputAction extends EditorAction {
711
708
  constructor() {
712
709
  super({
713
710
  id: 'repl.action.acceptInput',
714
- label: ( (localize(
715
- { key: 'actions.repl.acceptInput', comment: ['Apply input from the debug console input box'] },
716
- "REPL Accept Input"
717
- ))),
711
+ label: localizeWithPath('vs/workbench/contrib/debug/browser/repl', { key: 'actions.repl.acceptInput', comment: ['Apply input from the debug console input box'] }, "REPL Accept Input"),
718
712
  alias: 'REPL Accept Input',
719
713
  precondition: CONTEXT_IN_DEBUG_REPL,
720
714
  kbOpts: {
@@ -734,7 +728,7 @@ class FilterReplAction extends EditorAction {
734
728
  constructor() {
735
729
  super({
736
730
  id: 'repl.action.filter',
737
- label: ( (localize('repl.action.filter', "REPL Focus Content to Filter"))),
731
+ label: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'repl.action.filter', "REPL Focus Content to Filter"),
738
732
  alias: 'REPL Filter',
739
733
  precondition: CONTEXT_IN_DEBUG_REPL,
740
734
  kbOpts: {
@@ -753,7 +747,7 @@ class ReplCopyAllAction extends EditorAction {
753
747
  constructor() {
754
748
  super({
755
749
  id: 'repl.action.copyAll',
756
- label: ( (localize('actions.repl.copyAll', "Debug: Console Copy All"))),
750
+ label: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'actions.repl.copyAll', "Debug: Console Copy All"),
757
751
  alias: 'Debug Console Copy All',
758
752
  precondition: CONTEXT_IN_DEBUG_REPL,
759
753
  });
@@ -789,7 +783,7 @@ registerAction2(class extends ViewAction {
789
783
  super({
790
784
  id: selectReplCommandId,
791
785
  viewId: REPL_VIEW_ID,
792
- title: ( (localize('selectRepl', "Select Debug Console"))),
786
+ title: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'selectRepl', "Select Debug Console"),
793
787
  f1: false,
794
788
  menu: {
795
789
  id: MenuId.ViewTitle,
@@ -821,7 +815,7 @@ registerAction2(class extends ViewAction {
821
815
  super({
822
816
  id: 'workbench.debug.panel.action.clearReplAction',
823
817
  viewId: REPL_VIEW_ID,
824
- title: { value: ( (localize('clearRepl', "Clear Console"))), original: 'Clear Console' },
818
+ title: { value: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'clearRepl', "Clear Console"), original: 'Clear Console' },
825
819
  f1: true,
826
820
  icon: debugConsoleClearAll,
827
821
  menu: [{
@@ -838,14 +832,14 @@ registerAction2(class extends ViewAction {
838
832
  }
839
833
  runInView(_accessor, view) {
840
834
  view.clearRepl();
841
- aria.status(( (localize('debugConsoleCleared', "Debug console was cleared"))));
835
+ aria.status(localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'debugConsoleCleared', "Debug console was cleared"));
842
836
  }
843
837
  });
844
838
  registerAction2(class extends ViewAction {
845
839
  constructor() {
846
840
  super({
847
841
  id: 'debug.collapseRepl',
848
- title: ( (localize('collapse', "Collapse All"))),
842
+ title: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'collapse', "Collapse All"),
849
843
  viewId: REPL_VIEW_ID,
850
844
  menu: {
851
845
  id: MenuId.DebugConsoleContext,
@@ -863,7 +857,7 @@ registerAction2(class extends ViewAction {
863
857
  constructor() {
864
858
  super({
865
859
  id: 'debug.replPaste',
866
- title: ( (localize('paste', "Paste"))),
860
+ title: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'paste', "Paste"),
867
861
  viewId: REPL_VIEW_ID,
868
862
  precondition: ( (CONTEXT_DEBUG_STATE.notEqualsTo(getStateLabel(0 )))),
869
863
  menu: {
@@ -893,7 +887,7 @@ registerAction2(class extends ViewAction {
893
887
  constructor() {
894
888
  super({
895
889
  id: 'workbench.debug.action.copyAll',
896
- title: ( (localize('copyAll', "Copy All"))),
890
+ title: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'copyAll', "Copy All"),
897
891
  viewId: REPL_VIEW_ID,
898
892
  menu: {
899
893
  id: MenuId.DebugConsoleContext,
@@ -911,7 +905,7 @@ registerAction2(class extends Action2 {
911
905
  constructor() {
912
906
  super({
913
907
  id: 'debug.replCopy',
914
- title: ( (localize('copy', "Copy"))),
908
+ title: localizeWithPath('vs/workbench/contrib/debug/browser/repl', 'copy', "Copy"),
915
909
  menu: {
916
910
  id: MenuId.DebugConsoleContext,
917
911
  group: '2_cutcopypaste',