mirror of
https://github.com/Microsoft/calculator.git
synced 2025-08-21 05:43:10 -07:00
Check for ctrl when navigating to handle AltGr (#1054)
This commit is contained in:
parent
4f8db42855
commit
d11873caf6
1 changed files with 7 additions and 0 deletions
|
@ -642,6 +642,13 @@ void KeyboardShortcutManager::OnAcceleratorKeyActivated(CoreDispatcher ^, Accele
|
|||
return;
|
||||
}
|
||||
|
||||
// Ctrl is pressed in addition to alt, this means Alt Gr is intended. do not navigate.
|
||||
if ((static_cast<short>(Window::Current->CoreWindow->GetKeyState(VirtualKey::Control)) & static_cast<short>(CoreVirtualKeyStates::Down))
|
||||
== static_cast<short>(CoreVirtualKeyStates::Down))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
const auto& lookupMap = GetCurrentKeyDictionary(static_cast<MyVirtualKey>(key), altPressed);
|
||||
auto listItems = lookupMap.equal_range(static_cast<MyVirtualKey>(key));
|
||||
for (auto listIterator = listItems.first; listIterator != listItems.second; ++listIterator)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue