fix(editor): prevent empty text commit from advancing command edit_count

- Propagates commit status out of inline editors so commands know whether a real change occurred.

- Fixes TEXTEDIT's Undo step rolling back unrelated document actions when the user presses OK on empty/cleared existing MText.
This commit is contained in:
Karim Jerbi committed 2026-06-18 17:55:30 +01:00
1 parent 8e48bf02a0
commit 02f70ab0b3
3 files changed
+12 -10

No files matched your search

+4 -4
View File
@@ -4693,8 +4693,8 @@ impl OpenCADStudio {
Task::none()
}
Message::MTextOk => {
self.mtext_commit();
self.post_editor_closed(true)
let committed = self.mtext_commit();
self.post_editor_closed(committed)
}
Message::MTextCancel => {
self.mtext_cancel();
@@ -4708,8 +4708,8 @@ impl OpenCADStudio {
Task::none()
}
Message::TextInlineOk => {
self.text_inline_commit();
self.post_editor_closed(true)
let committed = self.text_inline_commit();
self.post_editor_closed(committed)
}
Message::DrawOrderSubmenuToggle => {