mirror of
https://github.com/brl/mutter.git
synced 2024-11-26 18:11:05 -05:00
data-device: Use a better variable name than "resource"
This commit is contained in:
parent
59fa74fed1
commit
6fea46e0cf
@ -199,7 +199,7 @@ drag_grab_focus (MetaWaylandPointerGrab *grab,
|
|||||||
MetaWaylandDragGrab *drag_grab = (MetaWaylandDragGrab*) grab;
|
MetaWaylandDragGrab *drag_grab = (MetaWaylandDragGrab*) grab;
|
||||||
MetaWaylandSeat *seat = drag_grab->seat;
|
MetaWaylandSeat *seat = drag_grab->seat;
|
||||||
struct wl_client *client;
|
struct wl_client *client;
|
||||||
struct wl_resource *resource, *offer = NULL;
|
struct wl_resource *data_device_resource, *offer = NULL;
|
||||||
struct wl_display *display;
|
struct wl_display *display;
|
||||||
guint32 serial;
|
guint32 serial;
|
||||||
wl_fixed_t sx, sy;
|
wl_fixed_t sx, sy;
|
||||||
@ -224,8 +224,8 @@ drag_grab_focus (MetaWaylandPointerGrab *grab,
|
|||||||
|
|
||||||
client = wl_resource_get_client (surface->resource);
|
client = wl_resource_get_client (surface->resource);
|
||||||
|
|
||||||
resource = wl_resource_find_for_client (&seat->data_device_resource_list, client);
|
data_device_resource = wl_resource_find_for_client (&seat->data_device_resource_list, client);
|
||||||
if (!resource)
|
if (!data_device_resource)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
display = wl_client_get_display (client);
|
display = wl_client_get_display (client);
|
||||||
@ -233,17 +233,17 @@ drag_grab_focus (MetaWaylandPointerGrab *grab,
|
|||||||
|
|
||||||
if (drag_grab->drag_data_source)
|
if (drag_grab->drag_data_source)
|
||||||
offer = meta_wayland_data_source_send_offer (drag_grab->drag_data_source,
|
offer = meta_wayland_data_source_send_offer (drag_grab->drag_data_source,
|
||||||
resource);
|
data_device_resource);
|
||||||
|
|
||||||
meta_wayland_pointer_get_relative_coordinates (grab->pointer, surface, &sx, &sy);
|
meta_wayland_pointer_get_relative_coordinates (grab->pointer, surface, &sx, &sy);
|
||||||
wl_data_device_send_enter (resource, serial, surface->resource,
|
wl_data_device_send_enter (data_device_resource, serial, surface->resource,
|
||||||
sx, sy, offer);
|
sx, sy, offer);
|
||||||
|
|
||||||
drag_grab->drag_focus = surface;
|
drag_grab->drag_focus = surface;
|
||||||
|
|
||||||
drag_grab->drag_focus_data_device = resource;
|
drag_grab->drag_focus_data_device = data_device_resource;
|
||||||
drag_grab->drag_focus_listener.notify = destroy_drag_focus;
|
drag_grab->drag_focus_listener.notify = destroy_drag_focus;
|
||||||
wl_resource_add_destroy_listener (resource, &drag_grab->drag_focus_listener);
|
wl_resource_add_destroy_listener (data_device_resource, &drag_grab->drag_focus_listener);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
Loading…
Reference in New Issue
Block a user