compositor: Set pointer->current before calling focus handler
The grab interface handlers all expect pointer->current to identify the surface under the pointer regardless of grabs etc. Thus, we need to set it before calling the focus handler.
This commit is contained in:
+1
-1
@@ -631,10 +631,10 @@ weston_device_repick(struct wl_seat *seat)
|
|||||||
|
|
||||||
if (&surface->surface != seat->pointer->current) {
|
if (&surface->surface != seat->pointer->current) {
|
||||||
interface = seat->pointer->grab->interface;
|
interface = seat->pointer->grab->interface;
|
||||||
|
seat->pointer->current = &surface->surface;
|
||||||
interface->focus(seat->pointer->grab, &surface->surface,
|
interface->focus(seat->pointer->grab, &surface->surface,
|
||||||
seat->pointer->current_x,
|
seat->pointer->current_x,
|
||||||
seat->pointer->current_y);
|
seat->pointer->current_y);
|
||||||
seat->pointer->current = &surface->surface;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
focus = (struct weston_surface *) seat->pointer->grab->focus;
|
focus = (struct weston_surface *) seat->pointer->grab->focus;
|
||||||
|
|||||||
Reference in New Issue
Block a user