Center selections when going to definition

Antonio Scandurra and Nathan Sobo created

Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Change summary

crates/editor/src/editor.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

Detailed changes

crates/editor/src/editor.rs 🔗

@@ -3021,7 +3021,7 @@ impl Editor {
                         .downcast::<Self>()
                         .unwrap();
                     target_editor.update(cx, |target_editor, cx| {
-                        target_editor.select_ranges([range], Some(Autoscroll::Fit), cx);
+                        target_editor.select_ranges([range], Some(Autoscroll::Center), cx);
                     });
                 }
             });