aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/commands.rs4
-rw-r--r--helix-term/src/keymap.rs5
2 files changed, 5 insertions, 4 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs
index 117ba046..e3c351f6 100644
--- a/helix-term/src/commands.rs
+++ b/helix-term/src/commands.rs
@@ -2825,6 +2825,10 @@ fn open_above(cx: &mut Context) {
fn normal_mode(cx: &mut Context) {
let (view, doc) = current!(cx.editor);
+ if doc.mode == Mode::Normal {
+ return;
+ }
+
doc.mode = Mode::Normal;
doc.append_changes_to_history(view.id);
diff --git a/helix-term/src/keymap.rs b/helix-term/src/keymap.rs
index f9bfcc50..a83b960e 100644
--- a/helix-term/src/keymap.rs
+++ b/helix-term/src/keymap.rs
@@ -436,7 +436,6 @@ impl Default for Keymaps {
"A" => append_to_line,
"o" => open_below,
"O" => open_above,
- // [<space> ]<space> equivalents too (add blank new line, no edit)
"d" => delete_selection,
// TODO: also delete without yanking
@@ -500,8 +499,7 @@ impl Default for Keymaps {
"K" => keep_selections,
// TODO: and another method for inverse
- // TODO: clashes with space mode
- "space" => keep_primary_selection,
+ "," => keep_primary_selection,
// "q" => record_macro,
// "Q" => replay_macro,
@@ -554,7 +552,6 @@ impl Default for Keymaps {
"p" => paste_clipboard_after,
"P" => paste_clipboard_before,
"R" => replace_selections_with_clipboard,
- "space" => keep_primary_selection,
"/" => global_search,
},
"z" => { "View"