We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b7fe33b commit a9f16bdCopy full SHA for a9f16bd
1 file changed
crates/outline/src/outline.rs
@@ -305,12 +305,12 @@ impl PickerDelegate for OutlineViewDelegate {
305
let selected_index = if is_query_empty {
306
let (buffer, cursor_offset) =
307
this.delegate.active_editor.update(cx, |editor, cx| {
308
- let buffer = editor.buffer().read(cx).snapshot(cx);
+ let snapshot = editor.display_snapshot(cx);
309
let cursor_offset = editor
310
.selections
311
- .newest::<MultiBufferOffset>(&editor.display_snapshot(cx))
+ .newest::<MultiBufferOffset>(&snapshot)
312
.head();
313
- (buffer, cursor_offset)
+ (snapshot.buffer().clone(), cursor_offset)
314
});
315
this.delegate
316
.matches
0 commit comments