After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 759670 - GtkPaned doesn't react to mouse dragging in some cases
GtkPaned doesn't react to mouse dragging in some cases
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: .General
3.19.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2015-12-19 16:29 UTC by Christoph Reiter (lazka)
Modified: 2016-01-08 21:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
screen recording (53.42 KB, image/gif)
2015-12-19 16:29 UTC, Christoph Reiter (lazka)
  Details
screen recording 2 (212.28 KB, image/gif)
2015-12-24 11:36 UTC, Christoph Reiter (lazka)
  Details
paned: Use GtkGestureDrag for anything else than touch (5.74 KB, patch)
2015-12-24 18:08 UTC, Carlos Garnacho
committed Details | Review

Description Christoph Reiter (lazka) 2015-12-19 16:29:11 UTC
Created attachment 317670 [details]
screen recording

I think this problem exists since the gesture work last cycle but I never bothered to report..

1) Open gtk3-widget-factory
2) Go to page 2
3) Move mouse to the panes at the bottom displaying "left"/"right"
4) Hover the pane somewhere at the bottom until the cursor changes to the drag icon
5) Slowly move the cursor up and keep it in the hover state
6) After a second press the button and drag -> the pane doesn't move as expected

screen recording attached
Comment 1 Timm Bäder 2015-12-24 10:34:54 UTC
In my experience, this happens whenever the first drag update is only in y direction, in which case the pan gesture is not a horizontal one anymore.

Should we just switch to a drag gesture instead? Or would that conflict with other gestures?
Comment 2 Carlos Garnacho 2015-12-24 11:25:28 UTC
Yes, that's probably the issue being seen. Back when I did the gesture porting, I thought this was a fancy place to use the pan gesture because there's one entire axis where dragging to is not that effective.

Actually, touch support kind of depends on the current gesture behavior, because the paned handle drag area is made wider there (covering partly both children) in order to ease drags. If eg. an hpaned consumes vertical drags too, those will be unable to make it to the children because the paned will consume those (e.g. scrolledwindows at both sides of the paned like in the filechooser case).

If it comes across as nonintuitive, should be easy enough preserve the current gesture for touch only, and adding a GtkGestureDrag for the mouse case. OTOH, I think this is the first bug since 3.14, so 1) people never noticed or 2) they never bothered to write a bug about it.
Comment 3 Christoph Reiter (lazka) 2015-12-24 11:36:11 UTC
Created attachment 317856 [details]
screen recording 2

I hit it quite frequently mostly when moving the mouse to the paned at an angle. See attached recording for a more "realistic" scenario.

(Btw, I've opened another paned bug some time ago, maybe it has a similar cause: bug 731574)
Comment 4 Matthias Clasen 2015-12-24 17:11:36 UTC
(In reply to Carlos Garnacho from comment #2)

> 
> If it comes across as nonintuitive, should be easy enough preserve the
> current gesture for touch only, and adding a GtkGestureDrag for the mouse
> case. OTOH, I think this is the first bug since 3.14, so 1) people never
> noticed or 2) they never bothered to write a bug about it.

I notice it all the time...
Comment 5 Carlos Garnacho 2015-12-24 18:08:21 UTC
Created attachment 317865 [details] [review]
paned: Use GtkGestureDrag for anything else than touch

The GtkGesturePan behavior of locking onto certain orientations may
come across as confusing, and is not strictly necessary for mice and
other pointing devices.

As GtkGesturePan is also a GtkGestureDrag, we just use the same
callbacks on both gestures.
Comment 6 Carlos Garnacho 2016-01-08 21:04:32 UTC
Attachment 317865 [details] pushed as e62f160 - paned: Use GtkGestureDrag for anything else than touch