~ubuntu-branches/ubuntu/utopic/compiz/utopic-proposed

« back to all changes in this revision

Viewing changes to src/window.cpp

  • Committer: Package Import Robot
  • Author(s): Ubuntu daily release, Chris Townsend
  • Date: 2014-04-04 21:41:53 UTC
  • mfrom: (3248.176.35)
  • Revision ID: package-import@ubuntu.com-20140404214153-5hmxpvjpd1laazhn
Tags: 1:0.9.11+14.04.20140404-0ubuntu1
[ Chris Townsend ]
* Fix issue where Compiz passively grabs all mouse buttons which
  severely affects scrolling in Gtk apps. Now only unconditionally
  grab buttons 1-3 for all windows except the desktop window and only
  grab other buttons when there is a modifier attached to it. (LP:
  #1171342)
* Only fade in and fade out a window when it's hidden if it's not in
  Show Desktop mode. This allows for a good fade out effect in Unity
  when exiting Spread while in Show Desktop mode. (LP: #1104236)

Show diffs side-by-side

added added

removed removed

Lines of Context:
5620
5620
        }
5621
5621
    }
5622
5622
 
5623
 
    if (onlyActions)
 
5623
    if (onlyActions || priv->type & CompWindowTypeDesktopMask)
5624
5624
        screen->updatePassiveButtonGrabs(serverFrame);
5625
5625
    else
5626
5626
    {
5627
 
        /* Grab everything */
5628
 
        XGrabButton (screen->dpy (),
5629
 
                     AnyButton,
5630
 
                     AnyModifier,
5631
 
                     serverFrame, false,
5632
 
                     ButtonPressMask | ButtonReleaseMask | ButtonMotionMask,
5633
 
                     GrabModeSync,
5634
 
                     GrabModeAsync,
5635
 
                     None,
5636
 
                     None);
 
5627
        /* Only grab buttons 1-3 */
 
5628
        for (int i = 1; i <= 3; i++)
 
5629
            XGrabButton (screen->dpy (),
 
5630
                         i,
 
5631
                         AnyModifier,
 
5632
                         serverFrame, false,
 
5633
                         ButtonPressMask | ButtonReleaseMask | ButtonMotionMask,
 
5634
                         GrabModeSync,
 
5635
                         GrabModeAsync,
 
5636
                         None,
 
5637
                         None);
5637
5638
    }
5638
5639
}
5639
5640