From 17d4cbe12510ffd7d82bb7bb70b10759a63b1f47 Mon Sep 17 00:00:00 2001 From: David Edmundson Date: Thu, 11 Oct 2018 22:58:16 +0100 Subject: [PATCH] [wayland] Correctly initialise m_requestedClientSize QSize default constructor does not set width/height to 0,0 but instead to an invalid size -1,-1. This went unnoticed as Qt5.12 corrected these values to the intended 0,0. Reviewed By: Roman Gilg --- shell_client.cpp | 2 +- shell_client.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/shell_client.cpp b/shell_client.cpp index 7a2387bcd6..53a497d10f 100644 --- a/shell_client.cpp +++ b/shell_client.cpp @@ -1184,7 +1184,7 @@ void ShellClient::requestGeometry(const QRect &rect) configureRequest.maximizeMode = m_requestedMaximizeMode; const QSize size = rect.size() - QSize(borderLeft() + borderRight(), borderTop() + borderBottom()); - m_requestedClientSize = size; + m_requestedClientSize = QSize(0, 0); if (m_shellSurface) { m_shellSurface->requestSize(size); diff --git a/shell_client.h b/shell_client.h index a29a62377c..15e9286892 100644 --- a/shell_client.h +++ b/shell_client.h @@ -220,7 +220,7 @@ private: QSize m_clientSize; // last size we requested or empty if we haven't sent an explicit request to the client // if empty the client should choose their own default size - QSize m_requestedClientSize; + QSize m_requestedClientSize = QSize(0, 0); struct PendingConfigureRequest { //note for wl_shell we have no serial, so serialId and m_lastAckedConfigureRequest will always be 0