aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/commands.rs
diff options
context:
space:
mode:
Diffstat (limited to 'helix-term/src/commands.rs')
-rw-r--r--helix-term/src/commands.rs20
1 files changed, 20 insertions, 0 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs
index 7233f1da..1b46aa62 100644
--- a/helix-term/src/commands.rs
+++ b/helix-term/src/commands.rs
@@ -1853,3 +1853,23 @@ pub fn jump_backward(cx: &mut Context) {
doc.set_selection(selection);
};
}
+
+//
+
+pub fn space_mode(cx: &mut Context) {
+ cx.on_next_key(move |cx, event| {
+ if let KeyEvent {
+ code: KeyCode::Char(ch),
+ ..
+ } = event
+ {
+ // TODO: temporarily show SPC in the mode list
+ match ch {
+ 'f' => file_picker(cx),
+ 'b' => buffer_picker(cx),
+ // ' ' => toggle_alternate_buffer(cx),
+ _ => (),
+ }
+ }
+ })
+}