on master help sign in
Exit select mode on surround commands (#4858)
commit1d21683321b9f94161be14b4ec5b506ed1669c7f authorJonathan LEI <me@xjonathan.dev> dateThu 24 Nov 2022, 10:07 (4 years ago) parentee06d4d
1 file changed+3
helix-term/src/commands.rs+3
helix-term/src/commands.rs+3
@@ -4582,6 +4582,7 @@ fn surround_add(cx: &mut Context) {
45824582 let transaction = Transaction::change(doc.text(), changes.into_iter())
45834583 .with_selection(Selection::new(ranges, selection.primary_index()));
45844584 apply_transaction(&transaction, doc, view);
4585+ exit_select_mode(cx);
45854586 })
45864587}
45874588
@@ -4621,6 +4622,7 @@ fn surround_replace(cx: &mut Context) {
46214622 }),
46224623 );
46234624 apply_transaction(&transaction, doc, view);
4625+ exit_select_mode(cx);
46244626 });
46254627 })
46264628}
@@ -4648,6 +4650,7 @@ fn surround_delete(cx: &mut Context) {
46484650 let transaction =
46494651 Transaction::change(doc.text(), change_pos.into_iter().map(|p| (p, p + 1, None)));
46504652 apply_transaction(&transaction, doc, view);
4653+ exit_select_mode(cx);
46514654 })
46524655}
46534656