mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 01:20:42 -05:00
wayland: Drop raise on click too
We'll handle this through GCD as well.
This commit is contained in:
parent
997188e914
commit
715fa91599
@ -280,31 +280,9 @@ handle_button_event (MetaWaylandSeat *seat,
|
|||||||
const ClutterEvent *event)
|
const ClutterEvent *event)
|
||||||
{
|
{
|
||||||
MetaWaylandPointer *pointer = &seat->pointer;
|
MetaWaylandPointer *pointer = &seat->pointer;
|
||||||
gboolean state = event->type == CLUTTER_BUTTON_PRESS;
|
|
||||||
uint32_t button;
|
|
||||||
MetaWaylandSurface *surface;
|
|
||||||
|
|
||||||
notify_motion (seat, event);
|
notify_motion (seat, event);
|
||||||
|
|
||||||
if (state && pointer->button_count == 1)
|
|
||||||
{
|
|
||||||
button = clutter_event_get_button (event);
|
|
||||||
pointer->grab_button = button;
|
|
||||||
pointer->grab_time = clutter_event_get_time (event);
|
|
||||||
pointer->grab_x = pointer->x;
|
|
||||||
pointer->grab_y = pointer->y;
|
|
||||||
|
|
||||||
/* FIXME: synth a XI2 event and handle in display.c */
|
|
||||||
surface = pointer->current;
|
|
||||||
if (button == CLUTTER_BUTTON_PRIMARY &&
|
|
||||||
surface &&
|
|
||||||
surface->window &&
|
|
||||||
surface->window->client_type == META_WINDOW_CLIENT_TYPE_WAYLAND)
|
|
||||||
{
|
|
||||||
meta_window_raise (surface->window);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
pointer->grab->interface->button (pointer->grab, event);
|
pointer->grab->interface->button (pointer->grab, event);
|
||||||
|
|
||||||
if (pointer->button_count == 1)
|
if (pointer->button_count == 1)
|
||||||
|
Loading…
Reference in New Issue
Block a user