We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f57a865 commit 30543d1Copy full SHA for 30543d1
helix-term/src/commands.rs
@@ -2507,7 +2507,22 @@ pub fn command_palette(cx: &mut Context) {
2507
on_next_key_callback: None,
2508
jobs: cx.jobs,
2509
};
2510
+ let focus = view!(ctx.editor).id;
2511
+
2512
command.execute(&mut ctx);
2513
2514
+ if ctx.editor.tree.contains(focus) {
2515
+ let config = ctx.editor.config();
2516
+ let mode = ctx.editor.mode();
2517
+ let view = view_mut!(ctx.editor, focus);
2518
+ let doc = doc_mut!(ctx.editor, &view.doc);
2519
2520
+ view.ensure_cursor_in_view(doc, config.scrolloff);
2521
2522
+ if mode != Mode::Insert {
2523
+ doc.append_changes_to_history(view);
2524
+ }
2525
2526
});
2527
compositor.push(Box::new(overlayed(picker)));
2528
},
0 commit comments