1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

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

This commit is contained in:
derMart 2015-01-14 23:44:38 +01:00
parent c018165497
commit 4540fb09aa

View File

@ -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);
}