Commit 12925b5c authored by Patrick José Pereira's avatar Patrick José Pereira

Settings: Change from foreach to c++11 for

Signed-off-by: 's avatarPatrick José Pereira <patrickelectric@gmail.com>
parent ea5de155
...@@ -71,7 +71,7 @@ VideoSettings::VideoSettings(QObject* parent) ...@@ -71,7 +71,7 @@ VideoSettings::VideoSettings(QObject* parent)
#endif #endif
#ifndef QGC_DISABLE_UVC #ifndef QGC_DISABLE_UVC
QList<QCameraInfo> cameras = QCameraInfo::availableCameras(); QList<QCameraInfo> cameras = QCameraInfo::availableCameras();
foreach (const QCameraInfo &cameraInfo, cameras) { for (const QCameraInfo &cameraInfo: cameras) {
videoSourceList.append(cameraInfo.description()); videoSourceList.append(cameraInfo.description());
} }
#endif #endif
...@@ -82,7 +82,7 @@ VideoSettings::VideoSettings(QObject* parent) ...@@ -82,7 +82,7 @@ VideoSettings::VideoSettings(QObject* parent)
videoSourceList.insert(0, videoDisabled); videoSourceList.insert(0, videoDisabled);
} }
QVariantList videoSourceVarList; QVariantList videoSourceVarList;
foreach (const QString& videoSource, videoSourceList) { for (const QString& videoSource: videoSourceList) {
videoSourceVarList.append(QVariant::fromValue(videoSource)); videoSourceVarList.append(QVariant::fromValue(videoSource));
} }
_nameToMetaDataMap[videoSourceName]->setEnumInfo(videoSourceList, videoSourceVarList); _nameToMetaDataMap[videoSourceName]->setEnumInfo(videoSourceList, videoSourceVarList);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment