diff options
Diffstat (limited to 'helix-term/src/commands.rs')
-rw-r--r-- | helix-term/src/commands.rs | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs index 7434d4cd..89855cbb 100644 --- a/helix-term/src/commands.rs +++ b/helix-term/src/commands.rs @@ -2314,7 +2314,7 @@ fn buffer_picker(cx: &mut Context) { .selection(view_id) .primary() .cursor_line(doc.text().slice(..)); - Some((path.clone()?, Some(line))) + Some((path.clone()?, Some((line, line)))) }, ); cx.push_layer(Box::new(picker)); @@ -2387,7 +2387,10 @@ fn symbol_picker(cx: &mut Context) { }, move |_editor, symbol| { let path = symbol.location.uri.to_file_path().unwrap(); - let line = Some(symbol.location.range.start.line as usize); + let line = Some(( + symbol.location.range.start.line as usize, + symbol.location.range.end.line as usize, + )); Some((path, line)) }, ); @@ -2820,7 +2823,10 @@ fn goto_impl( }, |_editor, location| { let path = location.uri.to_file_path().unwrap(); - let line = Some(location.range.start.line as usize); + let line = Some(( + location.range.start.line as usize, + location.range.end.line as usize, + )); Some((path, line)) }, ); |