diff --git a/src/vs/workbench/contrib/debug/browser/callStackView.ts b/src/vs/workbench/contrib/debug/browser/callStackView.ts index 9f65698bf2d..557b411e3d9 100644 --- a/src/vs/workbench/contrib/debug/browser/callStackView.ts +++ b/src/vs/workbench/contrib/debug/browser/callStackView.ts @@ -572,7 +572,10 @@ class ThreadsRenderer implements ITreeRenderer { static readonly ID = 'stackFrame'; - constructor(@ILabelService private readonly labelService: ILabelService) { } + constructor( + @ILabelService private readonly labelService: ILabelService, + @INotificationService private readonly notificationService: INotificationService + ) { } get templateId(): string { return StackFramesRenderer.ID; @@ -617,8 +620,12 @@ class StackFramesRenderer implements ITreeRenderer { - return stackFrame.restart(); + const action = new Action('debug.callStack.restartFrame', nls.localize('restartFrame', "Restart Frame"), 'codicon-debug-restart-frame', true, async () => { + try { + await stackFrame.restart(); + } catch (e) { + this.notificationService.error(e); + } }); data.actionBar.push(action, { icon: true, label: false }); }