diff --git a/src/cascadia/QueryExtension/ExtensionPalette.cpp b/src/cascadia/QueryExtension/ExtensionPalette.cpp index 61657a7810a..bfae56125be 100644 --- a/src/cascadia/QueryExtension/ExtensionPalette.cpp +++ b/src/cascadia/QueryExtension/ExtensionPalette.cpp @@ -382,6 +382,7 @@ namespace winrt::Microsoft::Terminal::Query::Extension::implementation const auto key = e.OriginalKey(); const auto coreWindow = CoreWindow::GetForCurrentThread(); const auto ctrlDown = WI_IsFlagSet(coreWindow.GetKeyState(winrt::Windows::System::VirtualKey::Control), CoreVirtualKeyStates::Down); + const auto shiftDown = WI_IsFlagSet(coreWindow.GetKeyState(winrt::Windows::System::VirtualKey::Shift), CoreVirtualKeyStates::Down); if (key == VirtualKey::Escape) { @@ -393,7 +394,7 @@ namespace winrt::Microsoft::Terminal::Query::Extension::implementation e.Handled(true); } - else if (key == VirtualKey::Enter) + else if (key == VirtualKey::Enter && !shiftDown) { if (const auto& textBox = e.OriginalSource().try_as()) { diff --git a/src/cascadia/QueryExtension/ExtensionPalette.xaml b/src/cascadia/QueryExtension/ExtensionPalette.xaml index 2f807a86e4a..f6f3dce09ff 100644 --- a/src/cascadia/QueryExtension/ExtensionPalette.xaml +++ b/src/cascadia/QueryExtension/ExtensionPalette.xaml @@ -392,6 +392,7 @@ Height="100" Margin="16,0,16,4" Padding="18,8,8,8" + AcceptsReturn="True" IsSpellCheckEnabled="False" PlaceholderText="{x:Bind QueryBoxPlaceholderText}" Text=""