Revert "Remove into SelectionEffects from .change_selections"

This reverts commit 28380d714d.
This commit is contained in:
Conrad Irwin 2025-06-27 14:06:17 -06:00
parent 28380d714d
commit 6e762d9c05
65 changed files with 625 additions and 837 deletions

View file

@ -1,4 +1,4 @@
use editor::{Bias, Editor, SelectionEffects, scroll::Autoscroll, styled_runs_for_code_label};
use editor::{Bias, Editor, scroll::Autoscroll, styled_runs_for_code_label};
use fuzzy::{StringMatch, StringMatchCandidate};
use gpui::{
App, Context, DismissEvent, Entity, FontWeight, ParentElement, StyledText, Task, WeakEntity,
@ -136,12 +136,9 @@ impl PickerDelegate for ProjectSymbolsDelegate {
workspace.open_project_item::<Editor>(pane, buffer, true, true, window, cx);
editor.update(cx, |editor, cx| {
editor.change_selections(
SelectionEffects::scroll(Autoscroll::center()),
window,
cx,
|s| s.select_ranges([position..position]),
);
editor.change_selections(Some(Autoscroll::center()), window, cx, |s| {
s.select_ranges([position..position])
});
});
})?;
anyhow::Ok(())