Repository navigation
Complete cross-platform global shortcuts; add the commercial-parity scorecard - #233
Merged
Merged
Conversation
…corecard Hold Rivet to the Tauri 2 / Electron feature floor. The audit found three capabilities below it: global shortcuts existed only on Linux (products hand-rolled macOS and Windows), clipboard, and native file dialogs. This change closes the first; the other two become visible, guarded rows on the new scorecard instead of tribal knowledge. - macOS RivetGlobalShortcuts: Carbon RegisterEventHotKey on the main-thread event loop, shared trigger grammar, explicit duplicate-id and duplicate-live-trigger refusal (RegisterHotKey gives Windows this for free; Carbon does not), parse(_:) public for tests and trigger rendering. ANSI virtual-key codes map through their Carbon constants — the codes follow the physical QWERTY layout, not the alphabet. - Windows rivet::system::GlobalShortcuts: RegisterHotKey on a message-only window with WM_HOTKEY dispatch, same callback shape (shortcut id, millisecond timestamp, portal-only activation token kept empty for signature parity). Compile-gated by the WinUI host build in CI. - docs/system-services.md documents all three adapters and the shared contract; docs/commercial-parity.md is the honest above/at/below/roadmap scorecard with rules of engagement, and the docs suite keeps it and its below-floor rows from silently disappearing.
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.
Why
Rivet is held to commercial standards — the Tauri 2 / Electron feature floors are the minimum. Auditing against Tauri 2's official plugin surface found three capabilities below floor: global shortcuts (Linux-only in-library; products hand-rolled macOS and Windows), clipboard, and native file dialogs. This PR closes global shortcuts across all three platforms and turns the whole audit into a maintained scorecard.
What
RivetGlobalShortcuts— CarbonRegisterEventHotKey, main-thread event loop, the shared trigger grammar, explicit duplicate-id and duplicate-live-trigger refusal (RegisterHotKey provides that on Windows; Carbon does not, so the adapter enforces parity itself).parse(_:)is public for tests and trigger rendering; ANSI virtual-key codes map through their Carbon constants because the codes follow the physical QWERTY layout, not the alphabet (kVK_ANSI_Tis 0x11 while T is the 20th letter — an arithmetic mapping silently produces wrong keys).rivet::system::GlobalShortcuts—RegisterHotKeyon a message-only window withWM_HOTKEYdispatch;ParseTriggerimplements the same grammar; register/unregister on the message-pumping thread. Compile-gated by the WinUI host build that CI builds on every PR; runtime verification rides the first product adoption.docs/commercial-parity.md— the honest above/at/below/roadmap scorecard versus Tauri 2 and Electron, with rules of engagement (a product hand-rolling the same capability twice is a library gap; below-floor rows outrank new surface area). The docs suite keeps the scorecard and its below-floor rows — clipboard, native file dialogs, mobile hosts — from silently disappearing.Testing
macOS: 3 new Swift suites-tests (parse table including the QWERTY-code trap cases, malformed-trigger rejection with
omittingEmptySubsequences: false, real registration lifecycle with duplicate refusal — using F20-class combos that cannot shadow user shortcuts). Fullswift testgreen. Windows: compile-gated in CI; docs suite 565 green with the new parity guards.