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 762235 - Port gdk_display_get_device* and similar functions to *_seat
Port gdk_display_get_device* and similar functions to *_seat
Status: RESOLVED FIXED
Product: nautilus
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Nautilus Maintainers
Nautilus Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-02-18 08:31 UTC by Carlos Soriano
Modified: 2016-05-03 11:13 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch for eel-canvas (2.28 KB, patch)
2016-04-17 17:22 UTC, Ernestas Kulik
none Details | Review
Patch for canvas-container (1.49 KB, patch)
2016-04-17 17:24 UTC, Ernestas Kulik
committed Details | Review
Patch for dnd (1.35 KB, patch)
2016-04-17 17:25 UTC, Ernestas Kulik
committed Details | Review
Patch for tree-view-drag-dest (1.61 KB, patch)
2016-04-17 17:26 UTC, Ernestas Kulik
committed Details | Review
Patch for eel-canvas (2.27 KB, patch)
2016-04-18 06:39 UTC, Ernestas Kulik
none Details | Review
Patch for eel-canvas (10.63 KB, patch)
2016-04-26 19:43 UTC, Ernestas Kulik
committed Details | Review

Description Carlos Soriano 2016-02-18 08:31:24 UTC
The form is deprecated. Basically port any deprecation warning about *_device_* functions to *_seat_*
Comment 1 Ernestas Kulik 2016-04-17 17:22:45 UTC
Created attachment 326204 [details] [review]
Patch for eel-canvas
Comment 2 Ernestas Kulik 2016-04-17 17:24:47 UTC
Created attachment 326205 [details] [review]
Patch for canvas-container
Comment 3 Ernestas Kulik 2016-04-17 17:25:16 UTC
Created attachment 326206 [details] [review]
Patch for dnd
Comment 4 Ernestas Kulik 2016-04-17 17:26:11 UTC
Created attachment 326207 [details] [review]
Patch for tree-view-drag-dest
Comment 5 Ernestas Kulik 2016-04-17 17:26:58 UTC
My limited testing revealed no regressions, but proceed with caution still.
Comment 6 Ernestas Kulik 2016-04-18 06:39:33 UTC
Created attachment 326217 [details] [review]
Patch for eel-canvas

Messed up a call argument.
Comment 7 Carlos Soriano 2016-04-18 21:20:37 UTC
Review of attachment 326205 [details] [review]:

LGTM thanks!
Comment 8 Carlos Soriano 2016-04-18 21:20:57 UTC
Review of attachment 326206 [details] [review]:

ditto
Comment 9 Carlos Soriano 2016-04-18 21:21:21 UTC
Review of attachment 326207 [details] [review]:

sure!
Comment 10 Carlos Soriano 2016-04-18 21:39:00 UTC
Review of attachment 326217 [details] [review]:

Timestamp parameter is no longer necessary, so you can remove it.
Also, I don't have the knowledge to review it actually :/ sorry for that. Specifically:

::: eel/eel-canvas.c
@@ +873,3 @@
+				  NULL,
+				  NULL,
+				  NULL);

I'm not sure this is equivalent. Where is provided the event_mask? (I checked and I have no idea neither).
We need to check with gtk+ developers. Would you like to approach them in IRC on channel gtk+ on irc.gnome.org?
garnacho or mclasen are probably the people to reach.
Comment 11 Carlos Soriano 2016-04-22 13:57:44 UTC
Pushing the ones that are ok
Comment 12 Ernestas Kulik 2016-04-26 19:43:35 UTC
Created attachment 326798 [details] [review]
Patch for eel-canvas

gdk_seat_grab() does not take an event mask, because it grabs all the events, corresponding to the capabilities. In this case, all pointing capabilities (recommended, unless we /really/ only want the pointer only). The event type is checked against the mask in emit_event() if the item is grabbed, so, AFAICT, we’re in the clear.

I eliminated the NULL arguments (at a cost) in this one. Now, instead of time, eel_canvas_item_grab() takes an event argument, which it passes to gdk_seat_grab(), so all the calling functions have been modified accordingly. It’s still fine to pass NULL, however. The second NULL argument before was the prepare_func. While not completely necessary (in this case (I think)), it prepares the window for grabbing (in this case (also in the majority of cases), makes it visible).

Also touched up the documentation, because some comments were outdated.
Comment 13 Ernestas Kulik 2016-04-26 19:49:21 UTC
Changed the status of pushed patches.
Comment 14 Carlos Soriano 2016-04-28 10:40:49 UTC
Review of attachment 326798 [details] [review]:

Yeah this makes sense to me now, thanks!
Comment 15 Ernestas Kulik 2016-05-03 10:08:00 UTC
Attachment 326798 [details] committed as 225f2cf - eel-canvas: use GdkSeat operations
Comment 16 Ernestas Kulik 2016-05-03 10:11:26 UTC
Oops, sorry about that.

Attachment 326798 [details] pushed as 225f2cf - eel-canvas: use GdkSeat operations