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 723294 - Add touchscreen support for the testing widget
Add touchscreen support for the testing widget
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Mouse
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Ondrej Holy
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-01-30 15:32 UTC by Ondrej Holy
Modified: 2014-02-13 14:11 UTC
See Also:
GNOME target: 3.12
GNOME version: ---


Attachments
add touch support (1.18 KB, patch)
2014-01-30 15:34 UTC, Ondrej Holy
none Details | Review
add touch support (1.19 KB, patch)
2014-02-06 10:01 UTC, Ondrej Holy
committed Details | Review
remove unnecessary events (1022 bytes, patch)
2014-02-06 10:16 UTC, Ondrej Holy
needs-work Details | Review

Description Ondrej Holy 2014-01-30 15:32:09 UTC
Touchscreen doesn't work correctly with the testing widget. See: https://bugzilla.redhat.com/show_bug.cgi?id=1051045
Comment 1 Ondrej Holy 2014-01-30 15:34:19 UTC
Created attachment 267649 [details] [review]
add touch support
Comment 2 Ondrej Holy 2014-01-30 15:39:57 UTC
Adding GDK_TOUCH_MASK fixes this bug, however it is weird. GtkDrawingArea receives button_press_event with delay (sometimes e.g. 2 seconds) without GDK_TOUCH_MASK. With this mask it works like charm. Carlos could you look at please?
Comment 3 Carlos Garnacho 2014-01-30 16:15:19 UTC
What I think is necessary (and sufficient) is adding GDK_BUTTON_RELEASE_MASK, the lack of this in the drawing area event mask confuses GtkScrolledWindow kinetic scroll implementation, which thinks the touch is never released, and triggers the hold-still-to-start-selection gesture.

GDK_TOUCH_MASK also fixes this because it ensures the full touch sequence (begin/update/end) is listened for, but GDK_BUTTON_RELEASE_MASK should be sufficient as we're just checking pointer (emulation) features in that dialog.
Comment 4 Ondrej Holy 2014-02-06 10:01:01 UTC
Created attachment 268267 [details] [review]
add touch support

Use GDK_BUTTON_RELEASE_MASK instead of GDK_TOUCH_MASK, untested.
Comment 5 Ondrej Holy 2014-02-06 10:16:25 UTC
Created attachment 268270 [details] [review]
remove unnecessary events

There are unnecessary events for GtkLabel, so remove it...
Comment 6 Carlos Garnacho 2014-02-06 11:31:29 UTC
Comment on attachment 268267 [details] [review]
add touch support

I did test that one :), makes things work as expected too.
Comment 7 Bastien Nocera 2014-02-07 08:31:24 UTC
Review of attachment 268270 [details] [review]:

The commit message really needs more information than that.
Comment 8 Ondrej Holy 2014-02-13 14:01:52 UTC
Comment on attachment 268270 [details] [review]
remove unnecessary events

This patch is probably stupidity. It looks like glade is producing this code in some cases by default...
Comment 9 Ondrej Holy 2014-02-13 14:11:29 UTC
Comment on attachment 268267 [details] [review]
add touch support

Committed to master as commit 0c5044609d26b8a55f1b64b272f2587925cc513b.