summaryrefslogtreecommitdiffstats
path: root/src/sensorsquick
diff options
context:
space:
mode:
authorJuha Vuolle <juha.vuolle@insta.fi>2021-06-07 09:27:50 +0300
committerJuha Vuolle <juha.vuolle@insta.fi>2021-06-08 07:23:57 +0300
commitae82c50ca7fd5e356a736467e660acd976ec2e25 (patch)
tree055a8b2ac02d9bb7e1668755c7ac79e074e22e19 /src/sensorsquick
parenta17deb2390081107649b820d9838127880beedf4 (diff)
Replace Q_FOREACH with ranged for loops
Task-number: QTBUG-92505 Change-Id: I1e8334473c883f76285736f6a26138ea882f5351 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
Diffstat (limited to 'src/sensorsquick')
-rw-r--r--src/sensorsquick/qmlsensorglobal.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sensorsquick/qmlsensorglobal.cpp b/src/sensorsquick/qmlsensorglobal.cpp
index 4699a33d..eaa83342 100644
--- a/src/sensorsquick/qmlsensorglobal.cpp
+++ b/src/sensorsquick/qmlsensorglobal.cpp
@@ -86,7 +86,7 @@ QStringList QmlSensorGlobal::sensorTypes() const
QStringList ret;
const QList<QByteArray> sensorTypes = QSensor::sensorTypes();
ret.reserve(sensorTypes.count());
- foreach (const QByteArray &type, sensorTypes)
+ for (const QByteArray &type : sensorTypes)
ret << QString::fromLocal8Bit(type);
return ret;
}
@@ -102,7 +102,7 @@ QStringList QmlSensorGlobal::sensorsForType(const QString &type) const
QStringList ret;
const QList<QByteArray> sensors = QSensor::sensorsForType(type.toLocal8Bit());
ret.reserve(sensors.count());
- foreach (const QByteArray &identifier, sensors)
+ for (const QByteArray &identifier : sensors)
ret << QString::fromLocal8Bit(identifier);
return ret;
}