diff --git a/crates/gpui/src/app.rs b/crates/gpui/src/app.rs index d658f323f2ac8fe1fcdb83d74b5f0ec4aa5a5a83..38c3aba045c4771e8476dd0231f44eaa6a278301 100644 --- a/crates/gpui/src/app.rs +++ b/crates/gpui/src/app.rs @@ -1181,6 +1181,7 @@ impl MutableAppContext { MatchResult::Action(action) => { if self.dispatch_action_any(window_id, &responder_chain[0..=i], action.as_ref()) { + self.keystroke_matcher.clear_pending(); return Ok(true); } } diff --git a/crates/gpui/src/keymap.rs b/crates/gpui/src/keymap.rs index b1082123bccc772a8f820744a427e491db06bd19..bff1efbd248c3bd579432fbfc582157fc8cac4b4 100644 --- a/crates/gpui/src/keymap.rs +++ b/crates/gpui/src/keymap.rs @@ -93,6 +93,10 @@ impl Matcher { self.keymap.add_bindings(bindings); } + pub fn clear_pending(&mut self) { + self.pending.clear(); + } + pub fn push_keystroke( &mut self, keystroke: Keystroke,