T21a round 3 fix, after the cap
- TextInput records the selection each edit replaces, where every edit passes; the block editor's undo goes back to it, for typing, delete, cut and paste - TextInput's layout geometry moves to forms/text/geometry.rs - Reviews: T21a done, fixed after the cap, no fourth review
This commit is contained in:
1 parent
187f54253e
commit
14a8990793
7 files changed
+109
-74
No files matched your search
@@ -174,14 +174,6 @@ impl BlockEditor {
|
||||
}
|
||||
}
|
||||
|
||||
/// Where a key went down, before the field acts on it: the start a typing burst's undo goes back to.
|
||||
pub(crate) fn note_key(&mut self, key: u64, field: usize, cx: &Context<Self>) {
|
||||
let selection = self.blocks[self.index(key)].fields[field]
|
||||
.read(cx)
|
||||
.selection();
|
||||
self.typed_from = Some((key, field, selection));
|
||||
}
|
||||
|
||||
/// Records the document before a change to its blocks.
|
||||
pub(crate) fn before_change(&mut self, cx: &mut Context<Self>) {
|
||||
self.settle(true, cx);
|
||||
|
||||
Reference in new issue
Block a user