repaint after notify_button() ?
Pekka Paalanen
ppaalanen at gmail.com
Tue Feb 11 08:38:05 UTC 2020
On Mon, 10 Feb 2020 21:49:54 +0000
Josh Simonot <jsimonot at live.ca> wrote:
> Hello,
>
> I'm using compositor-drm.c as a starting point and am injecting
> remote input events, using compositor-rdp.c as an example.
>
> Currently the output doesn't repaint after "clicking" on a button by calling:
> notify_motion_absolute(seat, evtime, x, y);
> notify_button(seat, evtime, btn, state);
> notify_pointer_frame(seat);
> (with WL_POINTER_BUTTON_STATE_PRESSED, then WL_POINTER_BUTTON_STATE_RELEASED)
>
> I finally see the result of the button press after the clock updates,
> or if I run any gl app in the background (ex. weston-simple-egl).
> The buttons I'm clicking on is to launch weston-terminal and close
> the terminal. Same results when clicking within weston-clickdot
> app's window. I tried calling:
> weston_output_schedule_repaint(&output->base); with no success.
>
> How can I get these apps to trigger repaint when clicked?
Hi,
input events are not supposed to cause immediate repaints in the
compositor, except for pointer motion and that only for the pointer
cursor position. An input event might not result in anything visible on
its own, so causing a repaint automatically would be wrong.
Whatever (client) ends up receiving the input events may decide they
have some effect and repaint a part of their surface(s), which then
will cause content damage in the compositor and schedule a repaint.
Why that does not seem to work for you, I cannot guess. Nothing comes
to mind off-hand. Sounds like a bug somewhere.
FWIW, tests/weston-test.c is a plugin that can poke at input too. All
the screenshot tests rely on the compositor repainting after any damage
from clients, so the damage side should be fine in libweston core.
Maybe check what kind of Wayland protocol exchange you see around your
remote input events? Comparing WAYLAND_DEBUG=server vs.
WAYLAND_DEBUG=client should reveal any socket flushing issues (the
messages are printed when queued/dispatched, not when they cross the
socket).
Thanks,
pq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20200211/280daa7f/attachment.sig>
More information about the wayland-devel
mailing list