Repository navigation
feat(windows): window-wide app accelerators (PRODUCT-SPEC §8) - #57
Open
turinglambdaai wants to merge 3 commits into
Open
turinglambdaai wants to merge 3 commits into
turinglambdaai wants to merge 3 commits into
Conversation
Windows was the only host without the shared accelerator contract: no Ctrl+1…4 view switching, no Ctrl+N quick-add focus, no Ctrl+F search focus, no Ctrl+Shift+C completed toggle, and no database shortcuts — §8 promises them window-wide on every host, and macOS (⌘ menu commands) and Linux (GTK accelerators) already shipped. Install KeyboardAccelerators on RootGrid (XamlRoot-wide scope) in code: there is no View menu on Windows to attach them to, and each accelerator reuses the exact code path of its on-screen control — SwitchSmartView (extracted from the tile click handler), quick-add / search focus, and the completed toggle without double-firing its Checked handler. The two File-menu rows that exist carry KeyboardAcceleratorTextOverride hints. Also refresh the stale interaction status in README (both languages) and UX-BENCHMARKS §1.2: batch operations and the keyboard flow landed on all three hosts this cycle.
The WinUI 3 projection keeps KeyboardAccelerator and its invoked args in Microsoft.UI.Xaml.Input (as in UWP's Windows.UI.Xaml.Input), not Microsoft.UI.Input; CI caught the wrong namespace. The extra pch include is dropped again.
…lerators # Conflicts: # CHANGELOG.md
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of the v0.2.4 polish cycle (#55 audit).
Gap
Windows was the only host without the shared accelerator contract. PRODUCT-SPEC §8 promises Ctrl+1…4 / Ctrl+N / Ctrl+F / Ctrl+Shift+C (plus Ctrl+Shift+N / Ctrl+O) window-wide on every host; macOS ships the ⌘ menu commands and Linux the GTK accelerators, but Windows had no accelerator handling at all.
Implementation
KeyboardAccelerators installed onRootGridinInstallAppAccelerators()— XamlRoot-scoped, so they fire window-wide without opening a menu (Windows has no View menu to attach them to).SwitchSmartViewextracted fromOnSmartTileClick(tiles and Ctrl+1…4 share it).ToggleShowCompletedapplies the state only if the Checked/Unchecked event didn't already (no double reload).KeyboardAcceleratorTextOverridehints.winrt/Microsoft.UI.Input.hadded.Verification