File tree Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ use crate::Editor;
3
3
use gpui:: { Task as AsyncTask , WindowContext } ;
4
4
use project:: Location ;
5
5
use task:: { TaskContext , TaskVariables , VariableName } ;
6
- use text:: { Point , ToOffset , ToPoint } ;
6
+ use text:: { ToOffset , ToPoint } ;
7
7
use workspace:: Workspace ;
8
8
9
9
fn task_context_with_editor (
@@ -14,11 +14,7 @@ fn task_context_with_editor(
14
14
return AsyncTask :: ready ( None ) ;
15
15
} ;
16
16
let ( selection, buffer, editor_snapshot) = {
17
- let mut selection = editor. selections . newest :: < Point > ( cx) ;
18
- if editor. selections . line_mode {
19
- selection. start = Point :: new ( selection. start . row , 0 ) ;
20
- selection. end = Point :: new ( selection. end . row + 1 , 0 ) ;
21
- }
17
+ let selection = editor. selections . newest_adjusted ( cx) ;
22
18
let Some ( ( buffer, _, _) ) = editor
23
19
. buffer ( )
24
20
. read ( cx)
You can’t perform that action at this time.
0 commit comments