notedeck

One damus client to rule them all
git clone git://jb55.com/notedeck
Log | Files | Refs | README | LICENSE

commit 4c2173c23ac85177df1c34824f213ed5ab59b5c4
parent a48781b7aeb87af01e80c2009eadb41573c2940a
Author: William Casarin <jb55@jb55.com>
Date:   Wed, 14 Jan 2026 06:58:43 -0800

input: disable ctrl-forward/back nav when typing

This enables us to do ctrl-arrow-key-left to skip around words
without acidentally back-naving

Changelog-Fixed: disable ctrl-H back-nav when typing
Signed-off-by: William Casarin <jb55@jb55.com>

Diffstat:
Mcrates/notedeck_columns/src/app.rs | 17+++++++++++++++--
1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/crates/notedeck_columns/src/app.rs b/crates/notedeck_columns/src/app.rs @@ -71,6 +71,7 @@ fn handle_egui_events( input: &egui::InputState, columns: &mut Columns, hovered_column: Option<usize>, + wants_keyboard_input: bool, ) { for event in &input.raw.events { match event { @@ -81,7 +82,11 @@ fn handle_egui_events( .. } if *pressed => { // Browser-like navigation: Cmd+Arrow (macOS) / Ctrl+Arrow (others) - if (modifiers.ctrl || modifiers.command) && !modifiers.shift && !modifiers.alt { + if !wants_keyboard_input + && (modifiers.ctrl || modifiers.command) + && !modifiers.shift + && !modifiers.alt + { match key { egui::Key::ArrowLeft | egui::Key::H => { columns.get_selected_router().go_back(); @@ -159,7 +164,15 @@ fn try_process_event( ) -> Result<()> { let current_columns = get_active_columns_mut(app_ctx.i18n, app_ctx.accounts, &mut damus.decks_cache); - ctx.input(|i| handle_egui_events(i, current_columns, damus.hovered_column)); + let wants_keyboard_input = ctx.wants_keyboard_input(); + ctx.input(|i| { + handle_egui_events( + i, + current_columns, + damus.hovered_column, + wants_keyboard_input, + ) + }); try_process_events_core(app_ctx, ctx, |app_ctx, ev| match (&ev.event).into() { RelayEvent::Opened => {