SCM - fix context key for clearing the input (#215341)

This commit is contained in:
Ladislau Szomoru 2024-06-12 21:25:03 +02:00 committed by GitHub
parent b0a60ae2da
commit 7392790e74
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -386,7 +386,7 @@ KeybindingsRegistry.registerCommandAndKeybindingRule({
KeybindingsRegistry.registerCommandAndKeybindingRule({ KeybindingsRegistry.registerCommandAndKeybindingRule({
id: 'scm.clearInput', id: 'scm.clearInput',
weight: KeybindingWeight.WorkbenchContrib, weight: KeybindingWeight.WorkbenchContrib,
when: ContextKeyExpr.has('scmRepository'), when: ContextKeyExpr.and(ContextKeyExpr.has('scmRepository'), SuggestContext.Visible.toNegated()),
primary: KeyCode.Escape, primary: KeyCode.Escape,
handler: async (accessor) => { handler: async (accessor) => {
const scmService = accessor.get(ISCMService); const scmService = accessor.get(ISCMService);