From b0042a30c1d8c064e475eac7a0987ec39f32f5e7 Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Fri, 28 May 2021 08:47:05 +0300 Subject: [PATCH] x11: Pick better names for geometries before blocking The new names express better what "geometries before update blocking" are. --- src/x11client.cpp | 24 ++++++++++++------------ src/x11client.h | 6 +++--- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/x11client.cpp b/src/x11client.cpp index dd147859f6..2b37fc70da 100644 --- a/src/x11client.cpp +++ b/src/x11client.cpp @@ -4069,9 +4069,9 @@ void X11Client::moveResizeInternal(const QRect &rect, MoveResizeMode mode) m_bufferGeometry = frameRectToBufferRect(frameGeometry); if (pendingMoveResizeMode() == MoveResizeMode::None && - m_bufferGeometryBeforeUpdateBlocking == m_bufferGeometry && - m_frameGeometryBeforeUpdateBlocking == m_frameGeometry && - m_clientGeometryBeforeUpdateBlocking == m_clientGeometry) { + m_lastBufferGeometry == m_bufferGeometry && + m_lastFrameGeometry == m_frameGeometry && + m_lastClientGeometry == m_clientGeometry) { return; } if (areGeometryUpdatesBlocked()) { @@ -4079,16 +4079,16 @@ void X11Client::moveResizeInternal(const QRect &rect, MoveResizeMode mode) return; } - const QRect oldBufferGeometry = m_bufferGeometryBeforeUpdateBlocking; - const QRect oldFrameGeometry = m_frameGeometryBeforeUpdateBlocking; - const QRect oldClientGeometry = m_clientGeometryBeforeUpdateBlocking; + const QRect oldBufferGeometry = m_lastBufferGeometry; + const QRect oldFrameGeometry = m_lastFrameGeometry; + const QRect oldClientGeometry = m_lastClientGeometry; updateServerGeometry(); updateWindowRules(Rules::Position|Rules::Size); - m_bufferGeometryBeforeUpdateBlocking = m_bufferGeometry; - m_frameGeometryBeforeUpdateBlocking = m_frameGeometry; - m_clientGeometryBeforeUpdateBlocking = m_clientGeometry; + m_lastBufferGeometry = m_bufferGeometry; + m_lastFrameGeometry = m_frameGeometry; + m_lastClientGeometry = m_clientGeometry; screens()->setCurrent(this); workspace()->updateStackingOrder(); @@ -4107,11 +4107,11 @@ void X11Client::moveResizeInternal(const QRect &rect, MoveResizeMode mode) void X11Client::updateServerGeometry() { - const QRect oldBufferGeometry = m_bufferGeometryBeforeUpdateBlocking; + const QRect oldBufferGeometry = m_lastBufferGeometry; // Compute the old client rect, the client geometry is always inside the buffer geometry. - QRect oldClientRect = m_clientGeometryBeforeUpdateBlocking; - oldClientRect.translate(-m_bufferGeometryBeforeUpdateBlocking.topLeft()); + QRect oldClientRect = m_lastClientGeometry; + oldClientRect.translate(-m_lastBufferGeometry.topLeft()); if (oldBufferGeometry.size() != m_bufferGeometry.size() || oldClientRect != QRect(clientPos(), clientSize())) { diff --git a/src/x11client.h b/src/x11client.h index f2e4000f7c..00e313eccf 100644 --- a/src/x11client.h +++ b/src/x11client.h @@ -529,9 +529,9 @@ private: QMetaObject::Connection m_edgeGeometryTrackingConnection; QMargins m_clientFrameExtents; - QRect m_bufferGeometryBeforeUpdateBlocking; - QRect m_frameGeometryBeforeUpdateBlocking; - QRect m_clientGeometryBeforeUpdateBlocking; + QRect m_lastBufferGeometry; + QRect m_lastFrameGeometry; + QRect m_lastClientGeometry; QScopedPointer m_decorationRenderer; };