diff options
Diffstat (limited to 'src/client/qwaylandwindow.cpp')
-rw-r--r-- | src/client/qwaylandwindow.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/client/qwaylandwindow.cpp b/src/client/qwaylandwindow.cpp index 9bc400f8a..c3bfdeaff 100644 --- a/src/client/qwaylandwindow.cpp +++ b/src/client/qwaylandwindow.cpp @@ -94,7 +94,8 @@ QWaylandWindow::~QWaylandWindow() reset(false); const QWindow *parent = window(); - foreach (QWindow *w, QGuiApplication::topLevelWindows()) { + const auto tlw = QGuiApplication::topLevelWindows(); + for (QWindow *w : tlw) { if (w->transientParent() == parent) QWindowSystemInterface::handleCloseEvent(w); } @@ -786,7 +787,7 @@ bool QWaylandWindow::createDecoration() } if (hadDecoration != (bool)mWindowDecoration) { - foreach (QWaylandSubSurface *subsurf, mChildren) { + for (QWaylandSubSurface *subsurf : qAsConst(mChildren)) { QPoint pos = subsurf->window()->geometry().topLeft(); QMargins m = frameMargins(); subsurf->set_position(pos.x() + m.left(), pos.y() + m.top()); |