[wayland] Use setGeometry in resizeWithChecks

Summary:
Configure xdg-toplevel only through setGeometry method, so it's easier
to reason about how geometry is handled in XdgShellClient.

Reviewers: #kwin

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D24329
icc-effect-master
Vlad Zahorodnii 2019-09-26 18:11:25 +03:00
parent 84de8d135d
commit 7c3d014f21
1 changed files with 1 additions and 4 deletions

View File

@ -1259,7 +1259,6 @@ void XdgShellClient::handleCommitted()
void XdgShellClient::resizeWithChecks(int w, int h, ForceGeometry_t force)
{
Q_UNUSED(force)
QRect area = workspace()->clientArea(WorkArea, this);
// don't allow growing larger than workarea
if (w > area.width()) {
@ -1268,9 +1267,7 @@ void XdgShellClient::resizeWithChecks(int w, int h, ForceGeometry_t force)
if (h > area.height()) {
h = area.height();
}
if (m_xdgShellSurface) {
m_xdgShellSurface->configure(xdgSurfaceStates(), QSize(w, h));
}
setGeometry(x(), y(), w, h, force);
}
void XdgShellClient::unmap()