diff --git a/group.cpp b/group.cpp index 22c0c2744a..8cdaa3d3eb 100644 --- a/group.cpp +++ b/group.cpp @@ -346,7 +346,7 @@ void Workspace::updateMinimizedOfTransients(Client* c) { // if mainwindow is minimized or shaded, minimize transients too if (c->isMinimized()) { - for (ClientList::ConstIterator it = c->transients().constBegin(); + for (auto it = c->transients().constBegin(); it != c->transients().constEnd(); ++it) { if ((*it)->isModal()) @@ -363,7 +363,7 @@ void Workspace::updateMinimizedOfTransients(Client* c) } } else { // else unmiminize the transients - for (ClientList::ConstIterator it = c->transients().constBegin(); + for (auto it = c->transients().constBegin(); it != c->transients().constEnd(); ++it) { if ((*it)->isMinimized()) { @@ -384,7 +384,7 @@ void Workspace::updateMinimizedOfTransients(Client* c) */ void Workspace::updateOnAllDesktopsOfTransients(Client* c) { - for (ClientList::ConstIterator it = c->transients().constBegin(); + for (auto it = c->transients().constBegin(); it != c->transients().constEnd(); ++it) { if ((*it)->isOnAllDesktops() != c->isOnAllDesktops()) @@ -876,7 +876,7 @@ bool Client::hasTransientInternal(const Client* cl, bool indirect, ConstClientLi if (set.contains(this)) return false; set.append(this); - for (ClientList::ConstIterator it = transients().constBegin(); + for (auto it = transients().constBegin(); it != transients().constEnd(); ++it) if ((*it)->hasTransientInternal(cl, indirect, set)) @@ -910,7 +910,7 @@ ClientList Client::allMainClients() const AbstractClient* Client::findModal(bool allow_itself) { - for (ClientList::ConstIterator it = transients().constBegin(); + for (auto it = transients().constBegin(); it != transients().constEnd(); ++it) if (AbstractClient* ret = (*it)->findModal(true)) diff --git a/layers.cpp b/layers.cpp index 336aae3579..ad81345a25 100644 --- a/layers.cpp +++ b/layers.cpp @@ -853,7 +853,7 @@ void Client::updateLayer() return; StackingUpdatesBlocker blocker(workspace()); invalidateLayer(); // invalidate, will be updated when doing restacking - for (ClientList::ConstIterator it = transients().constBegin(), + for (auto it = transients().constBegin(), end = transients().constEnd(); it != end; ++it) (*it)->updateLayer(); }