xwayland: Process move-only client configure requests more quickly

For a move-only client configure request, treat it similarly to
view_move() by updating the scene-graph immediately, rather than waiting
for handle_commit().  Move-and-resize requests are handled the same as
before.

This (mostly?) fixes the glitchiness that was noticeable when dragging
an undecorated XWayland window (e.g. Audacious in Winamp mode).

Also:

- Reduce some code duplication in handle_request_configure() by
  simply calling configure(), as suggested by @johanmalm in #428.
- Factor out common logic after a move and/or resize into view_moved().
This commit is contained in:
John Lindgren 2022-07-17 23:42:04 -04:00 committed by Johan Malm
parent a0a5cf706e
commit 065c37d3f5
4 changed files with 38 additions and 55 deletions

View file

@ -419,6 +419,7 @@ void view_close(struct view *view);
*/
void view_move_resize(struct view *view, struct wlr_box geo);
void view_move(struct view *view, double x, double y);
void view_moved(struct view *view);
void view_minimize(struct view *view, bool minimized);
/* view_wlr_output - return the output that a view is mostly on */
struct wlr_output *view_wlr_output(struct view *view);