UI: Block signals while populating formats

Avoid unnecessarily triggering signals while populating
the ffmpeg formats combo box.
This commit is contained in:
kc5nra 2015-04-26 22:34:55 -05:00
parent 091a002c37
commit a090ed5795

View File

@ -416,6 +416,8 @@ void OBSBasicSettings::LoadColorRanges()
void OBSBasicSettings::LoadFormats()
{
ui->advOutFFFormat->blockSignals(true);
formats.reset(ff_format_supported());
const ff_format_desc *format = formats.get();
@ -441,6 +443,8 @@ void OBSBasicSettings::LoadFormats()
ui->advOutFFFormat->model()->sort(0);
ui->advOutFFFormat->insertItem(0, AV_FORMAT_DEFAULT_STR);
ui->advOutFFFormat->blockSignals(false);
}
static void AddCodec(QComboBox *combo, const ff_codec_desc *codec_desc)