xserver/hw
Erik Kurzinger 9a7484f95c xwayland: correctly report PresentCompleteModeCopy
After executing a PresentPixmap request using the copy path, Xwayland
will clear the vblank's pixmap field and re-queue it for the next msc so
that on the next frame a PresentCompleteNotify event will be delivered
to the client by present_execute_post.

While this does work, since the pixmap field of the vblank will be NULL
when present_execute_post is called, the mode reported in the event will
always be PresentCompleteModeSkip, even if the request *was* actually
executed with a copy.

To fix this, we introduce a new "copy_executed" flag in the
xwl_present_event struct. If xwl_present_execute sees that this flag is
set, it will fall straight through to present_execute_post like it does
if the window or pixmap is NULL. So, after executing a request with
present_execute_copy, instead of clearing the pixmap field we will set
the copy_executed flag to true. This will cause present_execute_post to
report the correct completion mode to the client when the
PresentCompleteNotify event is delivered on the next frame.

Signed-off-by: Erik Kurzinger <ekurzinger@nvidia.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1254>
(cherry picked from commit a0717e5f03)
2026-01-19 12:32:21 -08:00
..
kdrive drop remains of support for old Sun compilers 2026-01-19 12:32:18 -08:00
vfb Xvfb: Support up to 13 mouse buttons 2024-01-08 11:16:11 +00:00
xfree86 xfree86: use own dev-privates key for per-screen cursor 2026-01-19 12:32:21 -08:00
xnest xnest: use own dev-privates key for per-screen cursor 2026-01-19 12:32:21 -08:00
xquartz xquartz: Disable COMPOSITE at runtime 2023-01-17 15:17:45 -08:00
xwayland xwayland: correctly report PresentCompleteModeCopy 2026-01-19 12:32:21 -08:00
xwin xwin: winsock.h needs to be included earlier 2026-01-19 12:32:20 -08:00
meson.build Drop DMX DDX 2021-09-07 09:34:31 +00:00