diff options
author | Arno <arno@disconnect.de> | 2018-11-23 17:17:26 +0100 |
---|---|---|
committer | Arno <arno@disconnect.de> | 2018-11-23 17:17:26 +0100 |
commit | 7992144aca4a80cd9903a8ea7df0e210087871b1 (patch) | |
tree | 168c498d880036bc79c7487b58cbef20ebaa0a33 | |
parent | 2a45f1c77134f7352bf98e4bb7f5013cc993b97d (diff) | |
download | SheMov-7992144aca4a80cd9903a8ea7df0e210087871b1.tar.gz SheMov-7992144aca4a80cd9903a8ea7df0e210087871b1.tar.bz2 SheMov-7992144aca4a80cd9903a8ea7df0e210087871b1.zip |
foreach fixes for RandomTab
-rw-r--r-- | randomtab.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/randomtab.cpp b/randomtab.cpp index 2907d86..0b5f8d9 100644 --- a/randomtab.cpp +++ b/randomtab.cpp @@ -183,12 +183,12 @@ void RandomTab::setupGui(){ void RandomTab::writeSettings(){ QSettings s; QStringList selGenres; - foreach(QComboBox *c, mGenreBoxes){ + for(QComboBox *c : mGenreBoxes){ selGenres << c->currentText(); } s.setValue("random/genres", selGenres); QStringList selActors; - foreach(QComboBox *c,mActorBoxes){ + for(QComboBox *c : mActorBoxes){ selActors << c->currentText(); } s.setValue("random/actors", selActors); @@ -288,7 +288,7 @@ void RandomTab::select(){ // Genres QStringList genreIds; - foreach(QComboBox *c, mGenreBoxes){ + for(QComboBox *c : mGenreBoxes){ int curId = c->currentData(IdRole).toInt(); if(curId != -1){ genreIds << QString::number(curId); @@ -307,7 +307,7 @@ void RandomTab::select(){ // Actors QStringList actorIds; - foreach(QComboBox *c, mActorBoxes){ + for(QComboBox *c : mActorBoxes){ int curId = c->currentData(IdRole).toInt(); if(curId != -1){ actorIds << QString::number(curId); @@ -439,7 +439,7 @@ void RandomTab::playSelected(){ logMessage(tr("Playing Selected")); QStringList files; QModelIndexList idxs = mFileView->selectionModel()->selectedRows(FullPath); - foreach(QModelIndex i, idxs){ + for(QModelIndex i : idxs){ QString fp = i.data().toString(); logMessage(QString(tr("Adding %1")).arg(fp)); files << fp; |