wayland-pointer: Drop unused arg from focus grab interface method

https://bugzilla.gnome.org/show_bug.cgi?id=726123
This commit is contained in:
Rui Matos 2014-03-16 16:50:38 +01:00
parent 3c6dd5bf6d
commit 62e45b6d5e
4 changed files with 9 additions and 14 deletions

View File

@ -175,8 +175,7 @@ destroy_drag_focus (struct wl_listener *listener, void *data)
static void static void
drag_grab_focus (MetaWaylandPointerGrab *grab, drag_grab_focus (MetaWaylandPointerGrab *grab,
MetaWaylandSurface *surface, MetaWaylandSurface *surface)
const ClutterEvent *event)
{ {
MetaWaylandDragGrab *drag_grab = (MetaWaylandDragGrab*) grab; MetaWaylandDragGrab *drag_grab = (MetaWaylandDragGrab*) grab;
MetaWaylandSeat *seat = drag_grab->seat; MetaWaylandSeat *seat = drag_grab->seat;
@ -257,7 +256,7 @@ data_device_end_drag_grab (MetaWaylandDragGrab *drag_grab)
if (drag_grab->drag_data_source) if (drag_grab->drag_data_source)
wl_list_remove (&drag_grab->drag_data_source_listener.link); wl_list_remove (&drag_grab->drag_data_source_listener.link);
drag_grab_focus (&drag_grab->generic, NULL, NULL); drag_grab_focus (&drag_grab->generic, NULL);
meta_wayland_pointer_end_grab (drag_grab->generic.pointer); meta_wayland_pointer_end_grab (drag_grab->generic.pointer);
g_slice_free (MetaWaylandDragGrab, drag_grab); g_slice_free (MetaWaylandDragGrab, drag_grab);

View File

@ -78,8 +78,7 @@ pointer_handle_focus_resource_destroy (struct wl_listener *listener, void *data)
static void static void
default_grab_focus (MetaWaylandPointerGrab *grab, default_grab_focus (MetaWaylandPointerGrab *grab,
MetaWaylandSurface *surface, MetaWaylandSurface *surface)
const ClutterEvent *event)
{ {
MetaWaylandPointer *pointer = grab->pointer; MetaWaylandPointer *pointer = grab->pointer;
@ -385,7 +384,7 @@ meta_wayland_pointer_start_grab (MetaWaylandPointer *pointer,
grab->pointer = pointer; grab->pointer = pointer;
if (pointer->current) if (pointer->current)
interface->focus (pointer->grab, pointer->current, NULL); interface->focus (pointer->grab, pointer->current);
} }
void void
@ -395,7 +394,7 @@ meta_wayland_pointer_end_grab (MetaWaylandPointer *pointer)
pointer->grab = &pointer->default_grab; pointer->grab = &pointer->default_grab;
interface = pointer->grab->interface; interface = pointer->grab->interface;
interface->focus (pointer->grab, pointer->current, NULL); interface->focus (pointer->grab, pointer->current);
} }
typedef struct { typedef struct {
@ -415,15 +414,14 @@ typedef struct {
static void static void
popup_grab_focus (MetaWaylandPointerGrab *grab, popup_grab_focus (MetaWaylandPointerGrab *grab,
MetaWaylandSurface *surface, MetaWaylandSurface *surface)
const ClutterEvent *event)
{ {
MetaWaylandPopupGrab *popup_grab = (MetaWaylandPopupGrab*)grab; MetaWaylandPopupGrab *popup_grab = (MetaWaylandPopupGrab*)grab;
/* Popup grabs are in owner-events mode (ie, events for the same client /* Popup grabs are in owner-events mode (ie, events for the same client
are reported as normal) */ are reported as normal) */
if (surface && wl_resource_get_client (surface->resource) == popup_grab->grab_client) if (surface && wl_resource_get_client (surface->resource) == popup_grab->grab_client)
default_grab_focus (grab, surface, event); default_grab_focus (grab, surface);
else else
meta_wayland_pointer_set_focus (grab->pointer, NULL); meta_wayland_pointer_set_focus (grab->pointer, NULL);
} }

View File

@ -29,8 +29,7 @@
struct _MetaWaylandPointerGrabInterface struct _MetaWaylandPointerGrabInterface
{ {
void (*focus) (MetaWaylandPointerGrab *grab, void (*focus) (MetaWaylandPointerGrab *grab,
MetaWaylandSurface *surface, MetaWaylandSurface *surface);
const ClutterEvent *event);
void (*motion) (MetaWaylandPointerGrab *grab, void (*motion) (MetaWaylandPointerGrab *grab,
const ClutterEvent *event); const ClutterEvent *event);
void (*button) (MetaWaylandPointerGrab *grab, void (*button) (MetaWaylandPointerGrab *grab,

View File

@ -440,8 +440,7 @@ meta_wayland_seat_repick (MetaWaylandSeat *seat,
{ {
const MetaWaylandPointerGrabInterface *interface = const MetaWaylandPointerGrabInterface *interface =
pointer->grab->interface; pointer->grab->interface;
interface->focus (pointer->grab, interface->focus (pointer->grab, surface);
surface, for_event);
} }
} }