capture: the suggested shortcut is a UI affordance, so it lives in the UI
Android / Build, or is the channel already serving this? (push) Successful in 2s
CI & Build / Build now, or wait for Android? (push) Successful in 2s
CI & Build / Python lint (push) Successful in 3s
Android / Kotlin + Rust (APK) (push) Skipped
Desktop (Tauri) / Build, or is the channel already serving this? (push) Successful in 2s
CI & Build / TypeScript typecheck (push) Successful in 6s
CI & Build / Python tests (push) Successful in 11s
CI & Build / integration (push) Successful in 21s
CI & Build / Build & push image (push) Successful in 17s
Desktop (Tauri) / Windows installer (cross-compiled) (push) Successful in 2m26s
Desktop (Tauri) / Tauri desktop (Linux) (push) Successful in 4m31s
Desktop (Tauri) / Update manifest (push) Successful in 5s

`-D warnings` failed the Linux lane on `constant SUGGESTED is never used`, and
it was right — the suggestion is implemented in `bridge.ts` as
SUGGESTED_CAPTURE_SHORTCUT, and nothing in Rust ever read the copy here.

Deleted rather than exposed through a command. This side accepts any
combination the OS will take; picking one to put in front of someone as a
starting point is a UI decision, and a constant here would only be a second
copy of a string one layer reads and the other does not.

Worth noting what this run DID prove, since the previous one proved nothing:
the lockfile gate passed and the Windows job built the NSIS installer end to
end. So `tauri-plugin-global-shortcut`'s handler signature — the thing I could
not verify without a toolchain — is correct, and the feature compiles.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01K3MMqUtzX1TJgA1oypvm1c
This commit is contained in:
2026-09-01 18:13:31 -04:00
co-authored by Claude Opus 5
parent 6c0153be1e
commit 23a61365da
+6 -9
View File
@@ -11,8 +11,12 @@
//! it knows nothing about. Whatever default is picked is a key combination taken
//! away from something on somebody's machine, silently, at install time. So there
//! is no default: the feature is off until someone chooses a combination, and
//! choosing one is how it turns on. [`SUGGESTED`] is offered by the UI as a
//! starting point, not applied on its behalf.
//! choosing one is how it turns on.
//!
//! The suggestion the settings screen offers (`CommandOrControl+Shift+N`) lives in
//! the frontend, not here. It is a UI affordance — a starting point put in front of
//! someone — and this side accepts any combination the OS will take, so a constant
//! here would be a second copy of a string only the UI ever reads.
//!
//! ## Failure has to be visible
//!
@@ -34,13 +38,6 @@ const SHORTCUT_PREF: &str = "capture_shortcut";
/// The window the hotkey opens. Also the label the capability file grants to.
pub const CAPTURE_WINDOW: &str = "capture";
/// What the UI offers as a starting point. NOT applied automatically — see above.
///
/// `CommandOrControl+Shift+N`: the Command/Control split is Tauri's own portable
/// spelling, and Shift+N is rare enough to be free on most desktops while still
/// meaning "new" to the person pressing it.
pub const SUGGESTED: &str = "CommandOrControl+Shift+N";
/// Emitted to the main window after a capture is saved, so the board reloads.
///
/// The two windows hold separate copies of the frontend and therefore separate