From 7d11bbb906f3fe49b243c3acca1cffbb28915a6a Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 28 Nov 2022 16:50:01 +0000 Subject: Resolves: tdf#152128 consider input engine events as well as keystrokes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I2884c6feb388050dd962fba5ef85117da2a039d3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143411 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- sw/source/ui/dbui/mmaddressblockpage.cxx | 12 ++++++++++++ sw/source/ui/dbui/mmaddressblockpage.hxx | 1 + 2 files changed, 13 insertions(+) (limited to 'sw/source/ui') diff --git a/sw/source/ui/dbui/mmaddressblockpage.cxx b/sw/source/ui/dbui/mmaddressblockpage.cxx index 740687de3e89..ad4a7bfc4b83 100644 --- a/sw/source/ui/dbui/mmaddressblockpage.cxx +++ b/sw/source/ui/dbui/mmaddressblockpage.cxx @@ -26,6 +26,7 @@ #include #include #include +#include #include #include #include @@ -1100,6 +1101,17 @@ bool AddressMultiLineEdit::KeyInput(const KeyEvent& rKEvt) return WeldEditView::KeyInput(rKEvt); } +bool AddressMultiLineEdit::Command(const CommandEvent& rCEvt) +{ + if (rCEvt.GetCommand() == CommandEventId::StartExtTextInput || + rCEvt.GetCommand() == CommandEventId::EndExtTextInput || + rCEvt.GetCommand() == CommandEventId::ExtTextInput) + { + return true; + } + return WeldEditView::Command(rCEvt); +} + bool AddressMultiLineEdit::MouseButtonDown(const MouseEvent& rMEvt) { if (rMEvt.GetClicks() >= 2) diff --git a/sw/source/ui/dbui/mmaddressblockpage.hxx b/sw/source/ui/dbui/mmaddressblockpage.hxx index 3aaad88fe736..f69b446169ba 100644 --- a/sw/source/ui/dbui/mmaddressblockpage.hxx +++ b/sw/source/ui/dbui/mmaddressblockpage.hxx @@ -144,6 +144,7 @@ class AddressMultiLineEdit : public WeldEditView virtual css::uno::Reference GetDropTarget() override; virtual bool KeyInput(const KeyEvent& rKEvt) override; + virtual bool Command(const CommandEvent& rCEvt) override; virtual bool MouseButtonDown(const MouseEvent& rMEvt) override; public: -- cgit