QWindow::setFlags: return early if the flags didn't change
Prevents calling into QPlatformWindow::setWindowFlags() when there's no change. Change-Id: I2dccf3052b5895ee7f05623e6ed468be14bb0c0d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Sérgio Martins <sergio.martins@kdab.com>
This commit is contained in:
parent
c877af847a
commit
a3c9550d7c
@ -825,6 +825,9 @@ QSurfaceFormat QWindow::format() const
|
||||
void QWindow::setFlags(Qt::WindowFlags flags)
|
||||
{
|
||||
Q_D(QWindow);
|
||||
if (d->windowFlags == flags)
|
||||
return;
|
||||
|
||||
if (d->platformWindow)
|
||||
d->platformWindow->setWindowFlags(flags);
|
||||
d->windowFlags = flags;
|
||||
|
Loading…
x
Reference in New Issue
Block a user