sw/source/ui/dbui/mmaddressblockpage.cxx |   12 ++++++++++++
 sw/source/ui/dbui/mmaddressblockpage.hxx |    1 +
 2 files changed, 13 insertions(+)

New commits:
commit 7d11bbb906f3fe49b243c3acca1cffbb28915a6a
Author:     Caolán McNamara <caol...@redhat.com>
AuthorDate: Mon Nov 28 16:50:01 2022 +0000
Commit:     Caolán McNamara <caol...@redhat.com>
CommitDate: Tue Nov 29 10:37:03 2022 +0100

    Resolves: tdf#152128 consider input engine events as well as keystrokes
    
    Change-Id: I2884c6feb388050dd962fba5ef85117da2a039d3
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143411
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caol...@redhat.com>

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 <svl/grabbagitem.hxx>
 #include <svl/itemset.hxx>
 #include <utility>
+#include <vcl/commandevent.hxx>
 #include <vcl/event.hxx>
 #include <vcl/svapp.hxx>
 #include <vcl/weld.hxx>
@@ -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<css::datatransfer::dnd::XDropTarget> 
GetDropTarget() override;
 
     virtual bool KeyInput(const KeyEvent& rKEvt) override;
+    virtual bool Command(const CommandEvent& rCEvt) override;
     virtual bool MouseButtonDown(const MouseEvent& rMEvt) override;
 
 public:

Reply via email to