Forward notifications from Buffer in MultiBuffer

Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
Antonio Scandurra 2021-12-15 15:07:42 +01:00
parent 437145afbe
commit 59121a238a

View file

@ -527,6 +527,7 @@ impl MultiBuffer {
self.sync(cx);
let buffer = props.buffer.clone();
cx.observe(&buffer, |_, _, cx| cx.notify()).detach();
cx.subscribe(&buffer, Self::on_buffer_event).detach();
let buffer_snapshot = buffer.read(cx).snapshot();