Browse Source

fix resetting AVForm resolution combobox index to get change signal always fired during init

pull/1008/head
derMart 11 years ago
parent
commit
4540fb09aa
  1. 4
      src/widget/form/settings/avform.cpp

4
src/widget/form/settings/avform.cpp

@ -125,7 +125,9 @@ void AVForm::onResProbingFinished(QList<QSize> res) @@ -125,7 +125,9 @@ void AVForm::onResProbingFinished(QList<QSize> res)
bodyUI->videoModescomboBox->blockSignals(true);
for (QSize r : res)
bodyUI->videoModescomboBox->addItem(QString("%1x%2").arg(QString::number(r.width()),QString::number(r.height())), r);
bodyUI->videoModescomboBox->blockSignals(false);
//reset index, otherwise cameras with only one resolution won't get initialized
bodyUI->videoModescomboBox->setCurrentIndex(-1);
bodyUI->videoModescomboBox->blockSignals(false);
bodyUI->videoModescomboBox->setCurrentIndex(bodyUI->videoModescomboBox->count()-1);
}

Loading…
Cancel
Save