Convert Q_FOREACH loops to C++11 for loops.

Q_FOREACH will de deprecated soon.
This commit is contained in:
Felix Geyer
2016-09-02 19:51:51 +02:00
committed by Jonathan White
parent ad834f0f58
commit fff9e7ac46
31 changed files with 202 additions and 143 deletions

View File

@@ -21,6 +21,7 @@
#include <QtConcurrent>
#include <QElapsedTimer>
#include "core/Global.h"
#include "crypto/CryptoHash.h"
#include "crypto/SymmetricCipher.h"
@@ -63,7 +64,7 @@ CompositeKey& CompositeKey::operator=(const CompositeKey& key)
clear();
Q_FOREACH (const Key* subKey, key.m_keys) {
for (const Key* subKey : asConst(key.m_keys)) {
addKey(*subKey);
}
@@ -74,7 +75,7 @@ QByteArray CompositeKey::rawKey() const
{
CryptoHash cryptoHash(CryptoHash::Sha256);
Q_FOREACH (const Key* key, m_keys) {
for (const Key* key : m_keys) {
cryptoHash.addData(key->rawKey());
}