From 19b7864062462e56545cfcca8402659573524f60 Mon Sep 17 00:00:00 2001 From: Robin Date: Fri, 22 Jul 2022 03:23:00 +0200 Subject: keep jump/file history when using :split (#3031) * keep jump/file history when using :split * move history cloning into the switch function Co-authored-by: Robin --- helix-term/src/commands.rs | 2 -- 1 file changed, 2 deletions(-) (limited to 'helix-term/src') diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs index 12d988d0..6fdc215a 100644 --- a/helix-term/src/commands.rs +++ b/helix-term/src/commands.rs @@ -4083,13 +4083,11 @@ fn split(cx: &mut Context, action: Action) { let (view, doc) = current!(cx.editor); let id = doc.id(); let selection = doc.selection(view.id).clone(); - let offset = view.offset; cx.editor.switch(id, action); // match the selection in the previous view let (view, doc) = current!(cx.editor); - view.offset = offset; doc.set_selection(view.id, selection); } -- cgit v1.2.3-70-g09d2