xwm: Fix input regions

commit 0f99e081c4 broke xwayland client
input regions. The xwayland window manager sets input regions in the
pending state without going through the function that sets the
WESTON_SURFACE_DIRTY_INPUT bit.

Just add the dirty bit to the xwm code.

Also, fix the whitespace error the same patch introduced.

fixes 0f99e081c4

Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
This commit is contained in:
Derek Foreman 2024-07-12 12:12:02 -05:00
parent 3b7ef70d3a
commit d500dbd4e2
2 changed files with 2 additions and 1 deletions

View File

@ -4801,7 +4801,7 @@ weston_surface_commit_state(struct weston_surface *surface,
/* wl_surface.set_input_region */
if (status & (WESTON_SURFACE_DIRTY_SIZE | WESTON_SURFACE_DIRTY_INPUT)) {
pixman_region32_intersect_rect(&surface->input, &state->input,
0, 0,
0, 0,
surface->width, surface->height);
}

View File

@ -1442,6 +1442,7 @@ weston_wm_window_set_pending_state(struct weston_wm_window *window)
pixman_region32_fini(&window->surface->pending.input);
pixman_region32_init_rect(&window->surface->pending.input,
input_x, input_y, input_w, input_h);
window->surface->pending.status |= WESTON_SURFACE_DIRTY_INPUT;
xwayland_interface->set_window_geometry(window->shsurf,
input_x, input_y,