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

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Mon May 18 21:39:53 UTC 2020


 vcl/unx/gtk3/gtk3gtkinst.cxx |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 58981c2d316ffeaf626667fbd2822443588efbed
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sun May 17 19:33:35 2020 +0100
Commit:     Adolfo Jayme Barrientos <fitojb at ubuntu.com>
CommitDate: Mon May 18 23:39:22 2020 +0200

    Resolves: tdf#131076 GdkEventKey::state can contain e.g. num lock
    
    which we don't want to consider
    
    Change-Id: Idad3ae428450590b366897d08a845b43000b48e6
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94388
    Tested-by: Jenkins
    Reviewed-by: Adolfo Jayme Barrientos <fitojb at ubuntu.com>

diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx
index 93b2a94b4c07..14be34515a50 100644
--- a/vcl/unx/gtk3/gtk3gtkinst.cxx
+++ b/vcl/unx/gtk3/gtk3gtkinst.cxx
@@ -11454,12 +11454,12 @@ private:
             case KEY_RETURN:
                 m_aQuickSelectionEngine.Reset();
                 // tdf#131076 don't let bare return toggle menu popup active, but do allow deactive
-                if (nCode == KEY_RETURN && !pEvent->state && !m_bPopupActive)
+                if (nCode == KEY_RETURN && !aKeyCode.GetModifier() && !m_bPopupActive)
                     bDone = combobox_activate();
                 break;
             default:
                 // tdf#131076 let base space toggle menu popup when its not already visible
-                if (nCode == KEY_SPACE && !pEvent->state && !m_bPopupActive)
+                if (nCode == KEY_SPACE && !aKeyCode.GetModifier() && !m_bPopupActive)
                     bDone = false;
                 else
                     bDone = m_aQuickSelectionEngine.HandleKeyEvent(aKEvt);
@@ -12051,7 +12051,7 @@ private:
 
     bool signal_key_press(GdkEventKey* pEvent)
     {
-        if (pEvent->state) // only with no modifiers held
+        if (GtkSalFrame::GetMouseModCode(pEvent->state)) // only with no modifiers held
             return false;
 
         if (pEvent->keyval == GDK_KEY_KP_Up || pEvent->keyval == GDK_KEY_Up || pEvent->keyval == GDK_KEY_KP_Page_Up || pEvent->keyval == GDK_KEY_Page_Up ||


More information about the Libreoffice-commits mailing list