Remove Requirement for "Add to Watch" to be in debug mode (#153224)

There's no reason this shortcut should require debug mode to run, this would allow the user to pre-populate watch before starting a debug session.

Co-authored-by: Rob Lourens <roblourens@gmail.com>
This commit is contained in:
Justin Grote 2022-12-30 15:05:53 -08:00 committed by GitHub
parent acb9348ee9
commit 267b98d271
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -285,7 +285,7 @@ export class SelectionToWatchExpressionsAction extends EditorAction {
id: SelectionToWatchExpressionsAction.ID,
label: SelectionToWatchExpressionsAction.LABEL,
alias: 'Debug: Add to Watch',
precondition: ContextKeyExpr.and(EditorContextKeys.hasNonEmptySelection, CONTEXT_IN_DEBUG_MODE, EditorContextKeys.editorTextFocus),
precondition: ContextKeyExpr.and(EditorContextKeys.hasNonEmptySelection, EditorContextKeys.editorTextFocus),
contextMenuOpts: {
group: 'debug',
order: 1