[Libreoffice-commits] core.git: Branch 'libreoffice-4-4' - vcl/source

Julien Nabet serval2412 at yahoo.fr
Fri Apr 3 00:29:51 PDT 2015


 vcl/source/control/ilstbox.cxx |   22 +++++++++++++---------
 1 file changed, 13 insertions(+), 9 deletions(-)

New commits:
commit ae0de4ffdb480745b69d2d6413c656db4112d4a7
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Thu Mar 26 22:46:00 2015 +0100

    tdf#81813: Typing to select value in dropdown resets after space character
    
    Change-Id: I6972cdad9708a46bb8338590312196e55c4f8778
    Reviewed-on: https://gerrit.libreoffice.org/15024
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>
    (cherry picked from commit 44c87a5dc921ea6dd28fdc016c61aa62cfd4f4d6)
    Reviewed-on: https://gerrit.libreoffice.org/15098

diff --git a/vcl/source/control/ilstbox.cxx b/vcl/source/control/ilstbox.cxx
index 9c66383..29f5462 100644
--- a/vcl/source/control/ilstbox.cxx
+++ b/vcl/source/control/ilstbox.cxx
@@ -1356,6 +1356,7 @@ bool ImplListBoxWindow::ProcessKeyInput( const KeyEvent& rKEvt )
     bool bCtrl  = aKeyCode.IsMod1() || aKeyCode.IsMod3();
     bool bMod2 = aKeyCode.IsMod2();
     bool bDone = false;
+    bool bHandleKey = false;
 
     switch( aKeyCode.GetCode() )
     {
@@ -1571,7 +1572,7 @@ bool ImplListBoxWindow::ProcessKeyInput( const KeyEvent& rKEvt )
                 }
                 bDone = true;
             }
-            maQuickSelectionEngine.Reset();
+            bHandleKey = true;
         }
         break;
 
@@ -1594,18 +1595,21 @@ bool ImplListBoxWindow::ProcessKeyInput( const KeyEvent& rKEvt )
                 maQuickSelectionEngine.Reset();
 
                 bDone = true;
-                break;
             }
-        }
-        // fall through intentional
-        default:
-        {
-            if ( !IsReadOnly() )
+            else
             {
-                bDone = maQuickSelectionEngine.HandleKeyEvent( rKEvt );
+                bHandleKey = true;
             }
-          }
+        }
         break;
+
+        default:
+            bHandleKey = true;
+            break;
+    }
+    if (bHandleKey && !IsReadOnly())
+    {
+        bDone = maQuickSelectionEngine.HandleKeyEvent( rKEvt );
     }
 
     if  (   ( nSelect != LISTBOX_ENTRY_NOTFOUND )


More information about the Libreoffice-commits mailing list