Call on_focus on the root view when the window is originally created. Test dropping a focused view. Simplify test to avoid relying on emitting events.
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Nathan Sobo
and
Antonio Scandurra
created
8bbaa0b
Handle reversed selections correctly in `split_selection_into_lines`
4797ccf
Implement `split_selection_into_lines` for buffer
Antonio Scandurra
created
1c2f549
Don't report folds that touch the endpoints of the given range
Click to expand commit body
Fold ranges are exclusive, exactly like the query ranges. So if the end
of a fold coincides with the start of the query range, we shouldn't
report that fold. Analogously, if the start of a fold coincides with the
end of the query range, that fold shouldn't be reported.
cfb7c87
Merge pull request #41 from zed-industries/faster-fold-querying
Click to expand commit body
Optimize querying folds
Antonio Scandurra
created
6a2fe38
Verify `FoldMap::unfold` in randomized test
Antonio Scandurra
created
e6323f0
Fix handling of new files with new buffer/file structure
Max Brunsfeld
created
35e0eaa
Refocus root view if focused view is removed
Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Nathan Sobo
and
Max Brunsfeld
created
5e08a02
Don't retain entities after EntityTasks are dropped
Click to expand commit body
This allows us to spawn long-running tasks without leaking entities, but it also ensures that if we *do* hold on to a task, that the entity exists until the future or stream complete so that the task doesn't need to return an Option type.
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Nathan Sobo
and
Max Brunsfeld
created
4eac765
Replace zed::watch with postage::watch for settings
Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Nathan Sobo
and
Max Brunsfeld
created
ab10e27
Create a pending view handle before creating a view
Click to expand commit body
This way, if we create and drop a handle during the creation of a view, we don't drop the view before we have a chance to increment its initial reference count.
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Nathan Sobo
and
Max Brunsfeld
created
f408521
Gracefully handle a view being updated and removed in the same tick
Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Otherwise, the element never goes away because the view never goes away because the element is holding a strong reference.
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Nathan Sobo
and
Max Brunsfeld
created
290fcb4
In handle ::condition, re-poll on events as well as notifications
652fc9e
Remove `add_summary_with_ctx` and always require a ctx in `add_summary`
Antonio Scandurra
created
901525b
Implement `FoldMap`'s folds using a `SumTree`
Click to expand commit body
This required passing a `Context` object to `Summary` and introducing a
new `SeekDimension` trait that allows comparing two dimensions and pass
an additional context object.
Antonio Scandurra
created
7fb7a6a
Add a `Summary` trait in preparation of passing a context struct
Instead, store all views in a single top-level map that's keyed by window id and view id. This ensures we'll keep a view alive even if its window is gone, so long as we're holding a handle. This can happen with things like spawned tasks. We don't want to panic during a spawned task after we close the window.
Nathan Sobo
created
bf28aba
Restore Buffer::file field and workspace::Item trait
Max Brunsfeld
created
78a5d0a
Maintain workspace buffers state after saving untitled buffer
Max Brunsfeld
created
47d0349
Wait to update bufferview's file handle until save has completed