<p dir="ltr">Agreed. Absolute input needs to be handled separately. The usage pattern on an absolute input device is that the cursor warps to the new position, it didn't simply move from the old to the new.</p>
<p dir="ltr">As an example, pointer barriers shouldn't take effect on absolute input.</p>
<br><div class="gmail_quote"><div dir="ltr">On Tue, Oct 27, 2015, 10:40 AM Daniel Stone <<a href="mailto:daniel@fooishbar.org">daniel@fooishbar.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Jonas,<br>
<br>
On 13 May 2015 at 11:26, Jonas Ådahl <<a href="mailto:jadahl@gmail.com" target="_blank">jadahl@gmail.com</a>> wrote:<br>
> @@ -3182,18 +3182,20 @@ popup_grab_focus(struct weston_pointer_grab *grab)<br>
><br>
>  static void<br>
>  popup_grab_motion(struct weston_pointer_grab *grab, uint32_t time,<br>
> -                 wl_fixed_t x, wl_fixed_t y)<br>
> +                 struct weston_pointer_motion_event *event)<br>
>  {<br>
>         struct weston_pointer *pointer = grab->pointer;<br>
>         struct wl_resource *resource;<br>
> +       wl_fixed_t x, y;<br>
>         wl_fixed_t sx, sy;<br>
><br>
>         if (pointer->focus) {<br>
> +               weston_pointer_motion_to_abs(pointer, event, &x, &y);<br>
>                 weston_view_from_global_fixed(pointer->focus, x, y,<br>
>                                               &pointer->sx, &pointer->sy);<br>
>         }<br>
><br>
> -       weston_pointer_move(pointer, x, y);<br>
> +       weston_pointer_move(pointer, event);<br>
><br>
>         wl_resource_for_each(resource, &pointer->focus_resource_list) {<br>
>                 weston_view_from_global_fixed(pointer->focus,<br>
> diff --git a/ivi-shell/hmi-controller.c b/ivi-shell/hmi-controller.c<br>
> index bad2418..5cd5ac9 100644<br>
> --- a/ivi-shell/hmi-controller.c<br>
> +++ b/ivi-shell/hmi-controller.c<br>
> @@ -1360,16 +1360,19 @@ layer_set_pos(struct ivi_layout_layer *layer, wl_fixed_t pos_x,<br>
><br>
>  static void<br>
>  pointer_move_grab_motion(struct weston_pointer_grab *grab, uint32_t time,<br>
> -                        wl_fixed_t x, wl_fixed_t y)<br>
> +                        struct weston_pointer_motion_event *event)<br>
>  {<br>
>         struct pointer_move_grab *pnt_move_grab =<br>
>                 (struct pointer_move_grab *)grab;<br>
> -       wl_fixed_t pointer_pos[2] = {x, y};<br>
> +       wl_fixed_t pointer_pos[2] = {<br>
> +               wl_fixed_from_double(event->x),<br>
> +               wl_fixed_from_double(event->y),<br>
> +       };<br>
<br>
Should this also be weston_pointer_motion_to_abs()?<br>
<br>
> diff --git a/src/compositor-x11.c b/src/compositor-x11.c<br>
> index 5129e85..57a7d11 100644<br>
> --- a/src/compositor-x11.c<br>
> +++ b/src/compositor-x11.c<br>
> @@ -1105,8 +1106,14 @@ x11_compositor_deliver_motion_event(struct x11_compositor *c,<br>
>                                            wl_fixed_from_int(motion_notify->event_y),<br>
>                                            &x, &y);<br>
><br>
> +       event = (struct weston_pointer_motion_event) {<br>
> +               .mask = WESTON_POINTER_MOTION_REL,<br>
> +               .dx = wl_fixed_to_double(x - c->prev_x),<br>
> +               .dy = wl_fixed_to_double(y - c->prev_y)<br>
> +       };<br>
> +<br>
<br>
To be honest, I'm somewhat skeptical of faking relative motion from<br>
abs in general.<br>
<br>
Cheers,<br>
Daniel<br>
_______________________________________________<br>
wayland-devel mailing list<br>
<a href="mailto:wayland-devel@lists.freedesktop.org" target="_blank">wayland-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/wayland-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/wayland-devel</a><br>
</blockquote></div>