summaryrefslogtreecommitdiff
path: root/gdk/wayland
diff options
context:
space:
mode:
authorRob Bradford <rob@linux.intel.com>2012-07-16 13:39:32 +0100
committerRob Bradford <rob@linux.intel.com>2012-07-16 13:44:29 +0100
commit3f0f328fd1cce52227986f03b3c039693ee6fd65 (patch)
tree1998b4d2f6c6aa24e4bec1d812261f03213cd66c /gdk/wayland
parent1d080a01c19b06b6bf62c62c633ea3d18e2dcafd (diff)
downloadgtk+-3f0f328fd1cce52227986f03b3c039693ee6fd65.tar.gz
wayland: data_device.data_offer now has a safe object wrapper
The prototype for the listener has changed to provide a typesafe object rather than an id that you have to bind into an object yourself.
Diffstat (limited to 'gdk/wayland')
-rw-r--r--gdk/wayland/gdkdevice-wayland.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/gdk/wayland/gdkdevice-wayland.c b/gdk/wayland/gdkdevice-wayland.c
index c45eb217a8..07911b935b 100644
--- a/gdk/wayland/gdkdevice-wayland.c
+++ b/gdk/wayland/gdkdevice-wayland.c
@@ -818,23 +818,17 @@ static const struct wl_data_offer_listener data_offer_listener = {
static void
data_device_data_offer (void *data,
struct wl_data_device *data_device,
- uint32_t id)
+ struct wl_data_offer *_offer)
{
DataOffer *offer;
- g_debug (G_STRLOC ": %s data_device = %p id = %lu",
- G_STRFUNC, data_device, (long unsigned int)id);
-
/* This structure is reference counted to handle the case where you get a
* leave but are in the middle of transferring data
*/
offer = g_new0 (DataOffer, 1);
offer->ref_count = 1;
offer->types = g_ptr_array_new_with_free_func (g_free);
- offer->offer = (struct wl_data_offer *)
- wl_proxy_create_for_id ((struct wl_proxy *) data_device,
- id,
- &wl_data_offer_interface);
+ offer->offer = _offer;
/* The DataOffer structure is then retrieved later since this sets the user
* data.