Git: Eradicate Q_FOREACH loops

Change-Id: I29b6071ea244d1b3ae0701d36c90b1e93cf21fbb
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Orgad Shaneh
2017-02-04 23:08:17 +02:00
committed by Orgad Shaneh
parent e3eee3b2b9
commit e366e135b7
17 changed files with 86 additions and 62 deletions

View File

@@ -33,11 +33,13 @@
#include "gitconstants.h"
#include "ui_branchdialog.h"
#include <utils/qtcassert.h>
#include <utils/execmenu.h>
#include <vcsbase/vcsoutputwindow.h>
#include <coreplugin/documentmanager.h>
#include <utils/asconst.h>
#include <utils/execmenu.h>
#include <utils/qtcassert.h>
#include <QAction>
#include <QItemSelectionModel>
#include <QMessageBox>
@@ -217,7 +219,7 @@ void BranchDialog::checkout()
QList<Stash> stashes;
client->synchronousStashList(m_repository, &stashes);
foreach (const Stash &stash, stashes) {
for (const Stash &stash : Utils::asConst(stashes)) {
if (stash.message.startsWith(popMessageStart)) {
branchCheckoutDialog.foundStashForNextBranch();
break;
@@ -245,7 +247,7 @@ void BranchDialog::checkout()
QString stashName;
client->synchronousStashList(m_repository, &stashes);
foreach (const Stash &stash, stashes) {
for (const Stash &stash : Utils::asConst(stashes)) {
if (stash.message.startsWith(popMessageStart)) {
stashName = stash.name;
break;