Apply autoscroll_on_clicks
when extending selection (#28235)
Closes https://github.com/zed-industries/zed/issues/22240 Release Notes: - Fixed `autoscroll_on_clicks` not being applied when expanding selection Co-authored-by: Kirill Bulatov <kirill@zed.dev>
This commit is contained in:
parent
a0bfe4d293
commit
86cc5c2b55
1 changed files with 3 additions and 1 deletions
|
@ -2952,7 +2952,9 @@ impl Editor {
|
|||
_ => {}
|
||||
}
|
||||
|
||||
self.change_selections(Some(Autoscroll::fit()), window, cx, |s| {
|
||||
let auto_scroll = EditorSettings::get_global(cx).autoscroll_on_clicks;
|
||||
|
||||
self.change_selections(auto_scroll.then(Autoscroll::fit), window, cx, |s| {
|
||||
s.set_pending(pending_selection, pending_mode)
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue