[Libreoffice-commits] core.git: sfx2/source

Michael Meeks (via logerrit) logerrit at kemper.freedesktop.org
Wed Oct 2 14:54:28 UTC 2019


 sfx2/source/view/lokhelper.cxx |   13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

New commits:
commit f51d4014de0d2da352ac1773c6464933c4bac836
Author:     Michael Meeks <michael.meeks at collabora.com>
AuthorDate: Tue Jul 16 15:38:23 2019 +0100
Commit:     Michael Meeks <michael.meeks at collabora.com>
CommitDate: Wed Oct 2 16:53:17 2019 +0200

    Adopt a more brute-force approach for deleting text for now.
    
    Change-Id: Ib5e75703a50ec89716542c45bc9dd58f0e631509
    Reviewed-on: https://gerrit.libreoffice.org/79881
    Tested-by: Jenkins
    Reviewed-by: Michael Meeks <michael.meeks at collabora.com>

diff --git a/sfx2/source/view/lokhelper.cxx b/sfx2/source/view/lokhelper.cxx
index f5d182ffcfbe..f9c559093861 100644
--- a/sfx2/source/view/lokhelper.cxx
+++ b/sfx2/source/view/lokhelper.cxx
@@ -319,8 +319,19 @@ namespace
         switch (pLOKEv->mnEvent)
         {
         case VclEventId::WindowKeyInput:
-            pLOKEv->mpWindow->KeyInput(pLOKEv->maKeyEvent);
+        {
+            sal_uInt16 nRepeat = pLOKEv->maKeyEvent.GetRepeat();
+            if (nRepeat > 0)
+            {
+                KeyEvent singlePress(pLOKEv->maKeyEvent.GetCharCode(),
+                                     pLOKEv->maKeyEvent.GetKeyCode());
+                for (sal_uInt16 i = 0; i <= nRepeat; ++i)
+                    pLOKEv->mpWindow->KeyInput(singlePress);
+            }
+            else
+                pLOKEv->mpWindow->KeyInput(pLOKEv->maKeyEvent);
             break;
+        }
         case VclEventId::WindowKeyUp:
             pLOKEv->mpWindow->KeyUp(pLOKEv->maKeyEvent);
             break;


More information about the Libreoffice-commits mailing list