Revert "Remove into SelectionEffects from .change_selections"
This reverts commit 28380d714d.
This commit is contained in:
@@ -4,6 +4,7 @@ use editor::{
|
||||
Anchor, Bias, DisplayPoint, Editor, MultiBuffer,
|
||||
display_map::{DisplaySnapshot, ToDisplayPoint},
|
||||
movement,
|
||||
scroll::Autoscroll,
|
||||
};
|
||||
use gpui::{Context, Entity, EntityId, UpdateGlobal, Window};
|
||||
use language::SelectionGoal;
|
||||
@@ -115,7 +116,7 @@ impl Vim {
|
||||
}
|
||||
}
|
||||
|
||||
editor.change_selections(Default::default(), window, cx, |s| {
|
||||
editor.change_selections(Some(Autoscroll::fit()), window, cx, |s| {
|
||||
s.select_anchor_ranges(ranges)
|
||||
});
|
||||
})
|
||||
@@ -168,7 +169,7 @@ impl Vim {
|
||||
}
|
||||
})
|
||||
.collect();
|
||||
editor.change_selections(Default::default(), window, cx, |s| {
|
||||
editor.change_selections(Some(Autoscroll::fit()), window, cx, |s| {
|
||||
s.select_ranges(points.into_iter().map(|p| p..p))
|
||||
})
|
||||
})
|
||||
@@ -250,7 +251,7 @@ impl Vim {
|
||||
}
|
||||
|
||||
if !should_jump && !ranges.is_empty() {
|
||||
editor.change_selections(Default::default(), window, cx, |s| {
|
||||
editor.change_selections(Some(Autoscroll::fit()), window, cx, |s| {
|
||||
s.select_anchor_ranges(ranges)
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user