Bug 149011

Summary: Block global shorcuts has broken
Product: [Plasma] kwin Reporter: Krister Bäckman <ixevix>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: ixevix
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Krister Bäckman 2007-08-20 00:57:19 UTC
Version:            (using KDE KDE 3.5.7)
Installed from:    Gentoo Packages
Compiler:          gcc-4.1.2 
OS:                Linux

After upgrading to KDE 3.5.7 the option "Block global shortcuts" in KWin doesn't block alt + mouse to move a window anymore. It has done this in previous versions of KDE.

I don't know if this is wanted behavior but I thought I should file a bug report. If it is indeed expected behavior then could it be made into an option rather than to force it either way?

This bug has forced me to downgrade to KDE 3.5.5 so that I can get the behavior I expect.
Comment 1 Lubos Lunak 2007-08-23 17:04:07 UTC
SVN commit 703895 by lunakl:

No idea why I removed this in r603293.
BUG: 149011



 M  +9 -0      events.cpp  


--- branches/KDE/3.5/kdebase/kwin/events.cpp #703894:703895
@@ -992,6 +992,15 @@
  */
 void Client::updateMouseGrab()
     {
+    if( workspace()->globalShortcutsDisabled())
+        {
+        XUngrabButton( qt_xdisplay(), AnyButton, AnyModifier, wrapperId());
+        // keep grab for the simple click without modifiers if needed (see below)
+        bool not_obscured = workspace()->topClientOnDesktop( workspace()->currentDesktop(), true, false ) == this;
+        if( !( !options->clickRaise || not_obscured ))
+            grabButton( None );
+        return;
+        }
     if( isActive() && !workspace()->forcedGlobalMouseGrab()) // see Workspace::establishTabBoxGrab()
         {
         // remove the grab for no modifiers only if the window