Hello community,

here is the log from the commit of package kglobalaccel for openSUSE:Factory 
checked in at 2018-06-02 11:53:29
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/kglobalaccel (Old)
 and      /work/SRC/openSUSE:Factory/.kglobalaccel.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "kglobalaccel"

Sat Jun  2 11:53:29 2018 rev:55 rq:613065 version:5.46.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/kglobalaccel/kglobalaccel.changes        
2018-05-18 14:21:07.081311542 +0200
+++ /work/SRC/openSUSE:Factory/.kglobalaccel.new/kglobalaccel.changes   
2018-06-02 11:53:44.344499241 +0200
@@ -1,0 +2,6 @@
+Wed May 30 13:19:34 UTC 2018 - [email protected]
+
+- Add upstream patch 
0001-Make-sure-ungrab-keyboard-request-is-processed-befor.patch:
+  * Fixes Alt-Tab being randomly ignored (kde#394689, boo#1094931)
+
+-------------------------------------------------------------------

New:
----
  0001-Make-sure-ungrab-keyboard-request-is-processed-befor.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ kglobalaccel.spec ++++++
--- /var/tmp/diff_new_pack.P6ixVa/_old  2018-06-02 11:53:44.968476353 +0200
+++ /var/tmp/diff_new_pack.P6ixVa/_new  2018-06-02 11:53:44.972476207 +0200
@@ -33,6 +33,8 @@
 Url:            http://www.kde.org
 Source:         
http://download.kde.org/stable/frameworks/%{_tar_path}/%{name}-%{version}.tar.xz
 Source1:        baselibs.conf
+# PATCH-FIX-UPSTREAM
+Patch0:         0001-Make-sure-ungrab-keyboard-request-is-processed-befor.patch
 BuildRequires:  cmake >= 3.0
 BuildRequires:  extra-cmake-modules >= %{_kf5_bugfix_version}
 BuildRequires:  fdupes
@@ -110,6 +112,7 @@
 
 %prep
 %setup -q
+%autopatch -p1
 
 %build
   %cmake_kf5 -d build -- -Dlconvert_executable=%{_kf5_libdir}/qt5/bin/lconvert

++++++ 0001-Make-sure-ungrab-keyboard-request-is-processed-befor.patch ++++++
>From 8c2521374bea3c6476effb7b472ac5f8fc199956 Mon Sep 17 00:00:00 2001
From: Sontol Bonggol <[email protected]>
Date: Wed, 30 May 2018 15:16:49 +0200
Subject: [PATCH] Make sure ungrab keyboard request is processed before
 emitting shortcut

Summary:
In some rare cases, the ungrab keyboard request is processed later than
the action of the key shortcut. This can make the application that try
to grab the keyboard (e.g. in kwin) fail to do so. The solution is to
use ungrab_keyboard_checked() and xcb_request_check() before emitting
the shortcut signal.

BUG: 394689

Reviewers: #frameworks, #plasma, mck182, davidedmundson

Reviewed By: #plasma, davidedmundson

Subscribers: davidedmundson, fvogt, kde-frameworks-devel

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D13128
---
 src/runtime/plugins/xcb/kglobalaccel_x11.cpp | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/runtime/plugins/xcb/kglobalaccel_x11.cpp 
b/src/runtime/plugins/xcb/kglobalaccel_x11.cpp
index d76f1d5..9b75ec4 100644
--- a/src/runtime/plugins/xcb/kglobalaccel_x11.cpp
+++ b/src/runtime/plugins/xcb/kglobalaccel_x11.cpp
@@ -241,8 +241,12 @@ bool KGlobalAccelImpl::x11KeyPress(xcb_key_press_event_t 
*pEvent)
        // Keyboard needs to be ungrabed after XGrabKey() activates the grab,
        // otherwise it becomes frozen.
     xcb_connection_t *c = QX11Info::connection();
-    xcb_ungrab_keyboard(c, XCB_TIME_CURRENT_TIME);
+    xcb_void_cookie_t cookie = xcb_ungrab_keyboard_checked(c, 
XCB_TIME_CURRENT_TIME);
     xcb_flush(c);
+    // xcb_flush() only makes sure that the ungrab keyboard request has been
+    // sent, but is not enough to make sure that request has been fulfilled. 
Use
+    // xcb_request_check() to make sure that the request has been processed.
+    xcb_request_check(c, cookie);

     int keyQt;
     if (!KKeyServer::xcbKeyPressEventToQt(pEvent, &keyQt)) {
--
2.17.0


Reply via email to