diff --git a/abstract_client.cpp b/abstract_client.cpp index 880d0883fd..e1e4ba8b3b 100644 --- a/abstract_client.cpp +++ b/abstract_client.cpp @@ -1306,9 +1306,14 @@ void AbstractClient::addRepaintDuringGeometryUpdates() m_visibleRectBeforeGeometryUpdate = deco_rect; } +QRect AbstractClient::frameGeometryBeforeUpdateBlocking() const +{ + return m_frameGeometryBeforeUpdateBlocking; +} + void AbstractClient::updateGeometryBeforeUpdateBlocking() { - m_geometryBeforeUpdateBlocking = frameGeometry(); + m_frameGeometryBeforeUpdateBlocking = frameGeometry(); } void AbstractClient::doMove(int, int) diff --git a/abstract_client.h b/abstract_client.h index a80067e560..b8a07d8503 100644 --- a/abstract_client.h +++ b/abstract_client.h @@ -1000,9 +1000,7 @@ protected: }; PendingGeometry_t pendingGeometryUpdate() const; void setPendingGeometryUpdate(PendingGeometry_t update); - QRect geometryBeforeUpdateBlocking() const { - return m_geometryBeforeUpdateBlocking; - } + QRect frameGeometryBeforeUpdateBlocking() const; void updateGeometryBeforeUpdateBlocking(); /** * Schedules a repaint for the visibleRect before and after a @@ -1220,7 +1218,7 @@ private: PendingGeometry_t m_pendingGeometryUpdate = PendingGeometryNone; friend class GeometryUpdatesBlocker; QRect m_visibleRectBeforeGeometryUpdate; - QRect m_geometryBeforeUpdateBlocking; + QRect m_frameGeometryBeforeUpdateBlocking; QRect m_virtualKeyboardGeometry; QRect m_keyboardGeometryRestore; diff --git a/geometry.cpp b/geometry.cpp index 17c023860f..335c11b589 100644 --- a/geometry.cpp +++ b/geometry.cpp @@ -1967,7 +1967,7 @@ void X11Client::setFrameGeometry(int x, int y, int w, int h, ForceGeometry_t for return; } QSize oldClientSize = m_frame.geometry().size(); - bool resized = (geometryBeforeUpdateBlocking().size() != geom.size() || pendingGeometryUpdate() == PendingGeometryForced); + bool resized = (frameGeometryBeforeUpdateBlocking().size() != geom.size() || pendingGeometryUpdate() == PendingGeometryForced); if (resized) { resizeDecoration(); m_frame.setGeometry(x, y, w, h); @@ -2008,7 +2008,7 @@ void X11Client::setFrameGeometry(int x, int y, int w, int h, ForceGeometry_t for if (oldClientSize != QSize(w,h)) discardWindowPixmap(); } - emit geometryShapeChanged(this, geometryBeforeUpdateBlocking()); + emit geometryShapeChanged(this, frameGeometryBeforeUpdateBlocking()); addRepaintDuringGeometryUpdates(); updateGeometryBeforeUpdateBlocking(); // TODO: this signal is emitted too often @@ -2065,7 +2065,7 @@ void X11Client::plainResize(int w, int h, ForceGeometry_t force) workspace()->updateStackingOrder(); if (oldClientSize != QSize(w,h)) discardWindowPixmap(); - emit geometryShapeChanged(this, geometryBeforeUpdateBlocking()); + emit geometryShapeChanged(this, frameGeometryBeforeUpdateBlocking()); addRepaintDuringGeometryUpdates(); updateGeometryBeforeUpdateBlocking(); // TODO: this signal is emitted too often diff --git a/internal_client.cpp b/internal_client.cpp index 8c98e8ab7c..f99a2f55c2 100644 --- a/internal_client.cpp +++ b/internal_client.cpp @@ -349,7 +349,7 @@ void InternalClient::setFrameGeometry(int x, int y, int w, int h, ForceGeometry_ if (pendingGeometryUpdate() != PendingGeometryNone) { // Reset geometry to the one before blocking, so that we can compare properly. - geom = geometryBeforeUpdateBlocking(); + geom = frameGeometryBeforeUpdateBlocking(); } if (geom == rect) { @@ -633,7 +633,7 @@ void InternalClient::commitGeometry(const QRect &rect) addWorkspaceRepaint(visibleRect()); syncGeometryToInternalWindow(); - const QRect oldGeometry = geometryBeforeUpdateBlocking(); + const QRect oldGeometry = frameGeometryBeforeUpdateBlocking(); updateGeometryBeforeUpdateBlocking(); emit geometryShapeChanged(this, oldGeometry); diff --git a/xdgshellclient.cpp b/xdgshellclient.cpp index cc1b65d151..6734b0902b 100644 --- a/xdgshellclient.cpp +++ b/xdgshellclient.cpp @@ -490,7 +490,7 @@ void XdgShellClient::setFrameGeometry(int x, int y, int w, int h, ForceGeometry_ if (pendingGeometryUpdate() != PendingGeometryNone) { // reset geometry to the one before blocking, so that we can compare properly - geom = geometryBeforeUpdateBlocking(); + geom = frameGeometryBeforeUpdateBlocking(); } const QSize requestedClientSize = newGeometry.size() - QSize(borderLeft() + borderRight(), borderTop() + borderBottom()); @@ -552,7 +552,7 @@ void XdgShellClient::doSetGeometry(const QRect &rect) updateWindowRules(Rules::Position | Rules::Size); } - const auto old = geometryBeforeUpdateBlocking(); + const auto old = frameGeometryBeforeUpdateBlocking(); addRepaintDuringGeometryUpdates(); updateGeometryBeforeUpdateBlocking(); emit geometryShapeChanged(this, old);