QWaylandWindow: Add a missing shell surface null check.
Caught by tst_QWidget::mapFromAndTo. Change-Id: I36e08ebfa3bae1ac8667ee828b1762867d71c66d Reviewed-by: Giulio Camuffo <giulio.camuffo@jollamobile.com>
This commit is contained in:
parent
d9ba141df9
commit
223fc10cde
@ -657,18 +657,21 @@ bool QWaylandWindow::setWindowStateInternal(Qt::WindowState state)
|
|||||||
// here. We use then this mState variable.
|
// here. We use then this mState variable.
|
||||||
mState = state;
|
mState = state;
|
||||||
createDecoration();
|
createDecoration();
|
||||||
switch (state) {
|
|
||||||
case Qt::WindowFullScreen:
|
if (mShellSurface) {
|
||||||
mShellSurface->setFullscreen();
|
switch (state) {
|
||||||
break;
|
case Qt::WindowFullScreen:
|
||||||
case Qt::WindowMaximized:
|
mShellSurface->setFullscreen();
|
||||||
mShellSurface->setMaximized();
|
break;
|
||||||
break;
|
case Qt::WindowMaximized:
|
||||||
case Qt::WindowMinimized:
|
mShellSurface->setMaximized();
|
||||||
mShellSurface->setMinimized();
|
break;
|
||||||
break;
|
case Qt::WindowMinimized:
|
||||||
default:
|
mShellSurface->setMinimized();
|
||||||
mShellSurface->setNormal();
|
break;
|
||||||
|
default:
|
||||||
|
mShellSurface->setNormal();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
QWindowSystemInterface::handleWindowStateChanged(window(), mState);
|
QWindowSystemInterface::handleWindowStateChanged(window(), mState);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user