Move several buffer-related messages to the background

This commit is contained in:
Antonio Scandurra 2022-03-03 12:18:19 +01:00
parent 1c14168f38
commit 14d26eeedc
7 changed files with 187 additions and 99 deletions

View file

@ -1291,6 +1291,13 @@ impl Buffer {
self.text.wait_for_edits(edit_ids)
}
pub fn wait_for_anchors<'a>(
&mut self,
anchors: impl IntoIterator<Item = &'a Anchor>,
) -> impl Future<Output = ()> {
self.text.wait_for_anchors(anchors)
}
pub fn wait_for_version(&mut self, version: clock::Global) -> impl Future<Output = ()> {
self.text.wait_for_version(version)
}