mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-08-13 01:57:07 -07:00
Convert all foreach() to range-based for()
This commit is contained in:
parent
62e71a15a4
commit
e2ee928017
64 changed files with 326 additions and 292 deletions
|
@ -33,6 +33,7 @@
|
|||
#include <QFile>
|
||||
#include <QHash>
|
||||
|
||||
#include "global.h"
|
||||
#include "logger.h"
|
||||
#include "profile.h"
|
||||
#include "utils/fs.h"
|
||||
|
@ -286,7 +287,7 @@ QString TransactionalSettings::deserialize(const QString &name, QVariantHash &da
|
|||
// Copy everything into memory. This means even keys inserted in the file manually
|
||||
// or that we don't touch directly in this code (eg disabled by ifdef). This ensures
|
||||
// that they will be copied over when save our settings to disk.
|
||||
foreach (const QString &key, settings->allKeys())
|
||||
for (const QString &key : copyAsConst(settings->allKeys()))
|
||||
data.insert(key, settings->value(key));
|
||||
|
||||
return settings->fileName();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue