Skip to content
  • Carlos Garnacho's avatar
    gtk/main: Keep implicit grab until all buttons are released · 43e48488
    Carlos Garnacho authored
    Currently, the implicit grab is broken on the first button release,
    in the case of pressing multiple buttons simultaneously. This means
    that we emit crossing events early, and the next button releases
    are sent to the pointer focus widget instead.
    
    Consider the implicit grab effective until all buttons are released,
    and only unset the pointer implicit grab (and emit crossing events)
    after there are no further buttons pressed. We do this by checking
    event modifiers, given button release events do contain the modifiers
    in effect at the time the event was generated, we have to look for
    exactly one active button modifier.
    
    Fixes weird pointer states after pressing multiple buttons on a
    widget.
    
    Fixes: #3426
    43e48488