diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2019-07-01 20:07:26 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2019-07-04 12:31:23 +0200 |
commit | 1289bd6045818249915028fb345ec29c4ead52e5 (patch) | |
tree | b249178edd73dbb0326bb17e774d4fc3b75d4b7f /tools/qmlcachegen | |
parent | d425848d0c09c49a734d1832e3a9f8e6fa12541b (diff) |
Eradicate Java-style iterators and mark the module free of them
Java-style iterators are scheduled to be deprecated, or at the very
least banned from use in Qt's own implementation.
Change-Id: I6a1aeceb22dfa13c4ed7443296455b60abed7d67
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tools/qmlcachegen')
-rw-r--r-- | tools/qmlcachegen/resourcefilemapper.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/tools/qmlcachegen/resourcefilemapper.cpp b/tools/qmlcachegen/resourcefilemapper.cpp index 6a00b39f2e..244874717f 100644 --- a/tools/qmlcachegen/resourcefilemapper.cpp +++ b/tools/qmlcachegen/resourcefilemapper.cpp @@ -50,10 +50,8 @@ bool ResourceFileMapper::isEmpty() const QStringList ResourceFileMapper::resourcePaths(const QString &fileName) { const QString absPath = QDir::cleanPath(QDir::current().absoluteFilePath(fileName)); - QHashIterator<QString, QString> it(qrcPathToFileSystemPath); QStringList resourcePaths; - while (it.hasNext()) { - it.next(); + for (auto it = qrcPathToFileSystemPath.cbegin(), end = qrcPathToFileSystemPath.cend(); it != end; ++it) { if (QFileInfo(it.value()) == QFileInfo(absPath)) resourcePaths.append(it.key()); } |