diff --git a/src/xdgshellclient.cpp b/src/xdgshellclient.cpp index 053eeac376..760aeedefe 100644 --- a/src/xdgshellclient.cpp +++ b/src/xdgshellclient.cpp @@ -1649,9 +1649,9 @@ void XdgToplevelClient::changeMaximize(bool horizontal, bool vertical, bool adju } // call into decoration update borders - if (isDecorated() && decoration()->client() && !(options->borderlessMaximizedWindows() && m_requestedMaximizeMode == KWin::MaximizeFull)) { + if (m_nextDecoration && !(options->borderlessMaximizedWindows() && m_requestedMaximizeMode == KWin::MaximizeFull)) { changeMaximizeRecursion = true; - const auto c = decoration()->client().toStrongRef(); + const auto c = m_nextDecoration->client().toStrongRef(); if ((m_requestedMaximizeMode & MaximizeVertical) != (oldMode & MaximizeVertical)) { Q_EMIT c->maximizedVerticallyChanged(m_requestedMaximizeMode & MaximizeVertical); }