[wayland] Queue XDG configure requests when resizing toplevel interactively
ClosedPublic

Authored by davidedmundson on Apr 9 2019, 12:24 AM.

Details

Summary

When resizing a window particularly from the left side, we need to
co-ordinate moving the window with when we get the resized buffer.

The code in AbstractClient::handleMoveResize checks
isWaitingForResizSync to make sure we never send more than one resize
request at a time to keep that in sync.

This makes sense on X and wl_shell_surface, but not on XDGShell where we
can track which resize events have been handled by the client.

ShellClient already keeps a stack of our pending configure requests and
handles everything appropriately, we don't need to block.

This results in a smoother dragging experience and avoids a potential
deadlock currently seen when a client may not reply to a no-op configure
request.

BUG: 403376

Test Plan

Async ack handling is covered by existing unit tests

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
davidedmundson created this revision.Apr 9 2019, 12:24 AM
Restricted Application added a project: KWin. · View Herald TranscriptApr 9 2019, 12:24 AM
Restricted Application added a subscriber: kwin. · View Herald Transcript
davidedmundson requested review of this revision.Apr 9 2019, 12:24 AM
zzag added a subscriber: zzag.EditedApr 9 2019, 5:39 AM

Are you able to move GTK clients after resizing them?

zzag added a comment.Apr 9 2019, 6:21 AM
This comment was removed by zzag.
zzag accepted this revision.Apr 9 2019, 7:07 AM
In D20397#446414, @zzag wrote:

Are you able to move GTK clients after resizing them?

There is yet another deadlock. The proper fix would be to implement xdg_surface::set_window_geometry I guess.

This revision is now accepted and ready to land.Apr 9 2019, 7:07 AM

Yeah, docs explicitly say to use window geometry.

Will do in another fix.

This revision was automatically updated to reflect the committed changes.
zzag added a comment.Apr 9 2019, 5:44 PM

Well, it kinda fixes that bug but there are still issues with moving/resizing GTK clients.