diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2021-10-07 16:48:46 +0200 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2021-10-20 16:25:16 +0200 |
commit | c175c1dc19d0edc8ca66e39f0b4b8af04e3d6c87 (patch) | |
tree | 04e074d7e034642a4e4025e106dc20db09ca9ee2 /sc/qa/unit/uicalc | |
parent | 85d53dafd8332fc9c7bf71d6cc9da19ab9d8e252 (diff) |
svx: Don't end text edit mode for all views
This allows multiple views to not disturb each other editing inside
a impress document. With the ending of text edit for all views still
enabled, one view can cancel other views text editing just by moving
or resizing a unrelated shape in the document.
To make this possible we also need a view-local undo manager for
the text edit mode, which is independent of the document undo
manager. When the text edit mode ends, all the changes will be
added as one change to the document undo stack. This prevents any
conflicts in the undo stack that could be made when 2 views are
editing the same document at the same time.
This also adds the test for the new use case and changes the existing
tests to reflect the change.
Change-Id: I04edb4f91d7e111a490c946f7121cbca75f818d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123220
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'sc/qa/unit/uicalc')
-rw-r--r-- | sc/qa/unit/uicalc/uicalc.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sc/qa/unit/uicalc/uicalc.cxx b/sc/qa/unit/uicalc/uicalc.cxx index 3c3d15f1d399..46c430c7e087 100644 --- a/sc/qa/unit/uicalc/uicalc.cxx +++ b/sc/qa/unit/uicalc/uicalc.cxx @@ -951,6 +951,9 @@ CPPUNIT_TEST_FIXTURE(ScUiCalcTest, testTdf119793) pModelObj->postKeyEvent(LOK_KEYEVENT_KEYINPUT, 'x', 0); pModelObj->postKeyEvent(LOK_KEYEVENT_KEYUP, 'x', 0); Scheduler::ProcessEventsToIdle(); + pModelObj->postKeyEvent(LOK_KEYEVENT_KEYINPUT, 0, KEY_ESCAPE); + pModelObj->postKeyEvent(LOK_KEYEVENT_KEYUP, 0, KEY_ESCAPE); + Scheduler::ProcessEventsToIdle(); dispatchCommand(mxComponent, ".uno:Undo", {}); Scheduler::ProcessEventsToIdle(); |