Batch undo - #82
Merged
Merged
Conversation
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
maxbrunsfeld
reviewed
Jun 9, 2021
| T: Rng, | ||
| { | ||
| let (old_ranges, new_text, operation) = self.randomly_edit(rng, 5, cx.as_deref_mut()); | ||
| let (old_ranges, new_text, operation) = self.randomly_edit(rng, 2, cx.as_deref_mut()); |
Collaborator
There was a problem hiding this comment.
Was it intentional leaving this at 2?
Member
Author
There was a problem hiding this comment.
Oops, nice catch! Restored this back to 5 on main (tests still pass with 1k iterations and 20 operations each). I remember switching this back but I guess I didn't save or who knows what. 😅 Thanks for noticing this!
Anthony-Eid
pushed a commit
to Anthony-Eid/zed
that referenced
this pull request
Jan 3, 2025
…ed-industries#82) * Keep scroll position when opening nested variables * Remove debug statement * Fix clippy * Update determine scroll position to cover more cases
9 tasks
jolutz
pushed a commit
to jolutz/zed
that referenced
this pull request
Aug 8, 2026
Bombfuse
pushed a commit
to gemdropgames/zed
that referenced
this pull request
Aug 10, 2026
Carried items: fix .map interceptor registration-order claim, add a clippy.toml disallowed-methods pin on WizardState::targets (use dest_targets() instead), compose_map_rgba unit test landed upstream via ggo PR zed-industries#82. Nine-crate sweep green (390 tests), clippy -D warnings clean, fmt clean, licenses clean, cargo check -p zed clean. MIGRATION.md counts re-tallied for the map editor and PNG import wizard rows. Merge drill zed-industries#7: 6 upstream commits, 0 conflicts.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request changes
UndoOperationto specify multiple edit IDs and, alongside that, it also provides a list of ranges and a version useful to locate the exact position of such edits in the local tree. This speeds up undoing/redoing with multiple cursors significantly because we only traverse and mutate the tree once.