[PR #9056] [MERGED] Fix CommandPalette to prefer inner interactions over bindings #27404

Open
opened 2026-01-31 09:21:46 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/9056
Author: @Don-Vito
Created: 2/5/2021
Status: Merged
Merged: 2/10/2021
Merged by: @DHowett

Base: mainHead: 9044-prefer-palette-keys


📝 Commits (4)

  • 54c2060 Fix CommandPalette to prefer inner interactions over bindings
  • 20e2682 Merge remote-tracking branch 'upstream/main' into 9044-prefer-palette-keys
  • 698aa10 Fix line endings
  • f6ada94 Merge remote-tracking branch 'upstream/main' into 9044-prefer-palette-keys

📊 Changes

3 files changed (+41 additions, -59 deletions)

View changed files

📝 src/cascadia/TerminalApp/CommandPalette.cpp (+25 -40)
📝 src/cascadia/TerminalApp/CommandPalette.h (+1 -2)
📝 src/cascadia/TerminalApp/CommandPalette.xaml (+15 -17)

📄 Description

PR Checklist

Detailed Description of the Pull Request / Additional comments

  • Currently TerminalPage registers on CmdPal key events:
    • To invoke bindings when the palette is open
    • Since some key combinations are not triggered by KeyDown
      it registers for PreviewKeyDown
  • As a result bindings might be preferred over navigation
    (e.g., ctrl+v will paste into Terminal rather than into search box)
  • To fix this, I moved all interactions inside the CmdPal into
    PreviewKeyDown as well
  • In addition, added specific handling for copy/paste
    which now allow to interact with search box even if not focused

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/9056 **Author:** [@Don-Vito](https://github.com/Don-Vito) **Created:** 2/5/2021 **Status:** ✅ Merged **Merged:** 2/10/2021 **Merged by:** [@DHowett](https://github.com/DHowett) **Base:** `main` ← **Head:** `9044-prefer-palette-keys` --- ### 📝 Commits (4) - [`54c2060`](https://github.com/microsoft/terminal/commit/54c2060e7aba2aa8b4624afd5cc9934aca9e0792) Fix CommandPalette to prefer inner interactions over bindings - [`20e2682`](https://github.com/microsoft/terminal/commit/20e26822f9bda5f03efa54ee3e4a26188f843f60) Merge remote-tracking branch 'upstream/main' into 9044-prefer-palette-keys - [`698aa10`](https://github.com/microsoft/terminal/commit/698aa10c25d906451e8237349dda961f71c79b44) Fix line endings - [`f6ada94`](https://github.com/microsoft/terminal/commit/f6ada941fd78408b75efbf19b1b4458301717d04) Merge remote-tracking branch 'upstream/main' into 9044-prefer-palette-keys ### 📊 Changes **3 files changed** (+41 additions, -59 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalApp/CommandPalette.cpp` (+25 -40) 📝 `src/cascadia/TerminalApp/CommandPalette.h` (+1 -2) 📝 `src/cascadia/TerminalApp/CommandPalette.xaml` (+15 -17) </details> ### 📄 Description ## PR Checklist * [x] Closes https://github.com/microsoft/terminal/issues/9044 * [x] CLA signed. * [ ] Tests added/passed * [ ] Documentation updated. * [ ] Schema updated. * [ ] I've discussed this with core contributors already. ## Detailed Description of the Pull Request / Additional comments * Currently TerminalPage registers on CmdPal key events: * To invoke bindings when the palette is open * Since some key combinations are not triggered by KeyDown it registers for PreviewKeyDown * As a result bindings might be preferred over navigation (e.g., ctrl+v will paste into Terminal rather than into search box) * To fix this, I moved all interactions inside the CmdPal into PreviewKeyDown as well * In addition, added specific handling for copy/paste which now allow to interact with search box even if not focused --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:21:46 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#27404