QMdiArea: port Q_FOREACH to ranged-for, one trivial case

Straightforward, the code was already iterating over a local const
copy, i.e. Q_FOREACH wasn't needed here.

Pick-to: 6.6 6.5
Task-number: QTBUG-115803
Change-Id: I3e806c54ce56b6eb06431eea6aea1758c8ecd154
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
This commit is contained in:
Ahmad Samir 2023-08-09 19:02:26 +03:00
parent c0a3806609
commit a6274fa39a

View File

@ -890,7 +890,7 @@ void QMdiAreaPrivate::rearrange(Rearranger *rearranger)
const bool reverseList = rearranger->type() == Rearranger::RegularTiler; const bool reverseList = rearranger->type() == Rearranger::RegularTiler;
const QList<QMdiSubWindow *> subWindows = subWindowList(activationOrder, reverseList); const QList<QMdiSubWindow *> subWindows = subWindowList(activationOrder, reverseList);
QSize minSubWindowSize; QSize minSubWindowSize;
foreach (QMdiSubWindow *child, subWindows) { for (QMdiSubWindow *child : subWindows) {
if (!sanityCheck(child, "QMdiArea::rearrange") || !child->isVisible()) if (!sanityCheck(child, "QMdiArea::rearrange") || !child->isVisible())
continue; continue;
if (rearranger->type() == Rearranger::IconTiler) { if (rearranger->type() == Rearranger::IconTiler) {