reload-all: Only update viewport when view focuses on the doc (#4901)
This commit is contained in:
parent
fc811726e0
commit
f0f295a667
1 changed files with 3 additions and 2 deletions
|
@ -1070,10 +1070,11 @@ fn reload_all(
|
|||
|
||||
for view_id in view_ids {
|
||||
let view = view_mut!(cx.editor, view_id);
|
||||
|
||||
if view.doc.eq(&doc_id) {
|
||||
view.ensure_cursor_in_view(doc, scrolloff);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue