Commit a43496bc authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

wayland: Fix maximize mode propagation to decoration

If the window is initially maximized, there won't be any current
decoration when XdgToplevelClient changes the maximize mode, we need to
use m_nextDecoration.

BUG: 450053


(cherry picked from commit c7685552)
parent f8d228c6
Pipeline #137209 passed with stage
in 15 minutes and 31 seconds
......@@ -1638,9 +1638,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);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment