Fixed crash after language change.
--HG-- branch : develop
This commit is contained in:
parent
f4aabbcf06
commit
840a4a9d92
|
@ -496,12 +496,15 @@ void TMainWindow::changeEvent(QEvent *event)
|
||||||
{
|
{
|
||||||
labelPatternUnit = new QLabel(tr("Pattern unit:"));
|
labelPatternUnit = new QLabel(tr("Pattern unit:"));
|
||||||
|
|
||||||
const qint32 index = comboBoxUnits->currentIndex();
|
if (comboBoxUnits != nullptr)
|
||||||
comboBoxUnits->blockSignals(true);
|
{
|
||||||
comboBoxUnits->clear();
|
const qint32 index = comboBoxUnits->currentIndex();
|
||||||
InitComboBoxUnits();
|
comboBoxUnits->blockSignals(true);
|
||||||
comboBoxUnits->setCurrentIndex(index);
|
comboBoxUnits->clear();
|
||||||
comboBoxUnits->blockSignals(false);
|
InitComboBoxUnits();
|
||||||
|
comboBoxUnits->setCurrentIndex(index);
|
||||||
|
comboBoxUnits->blockSignals(false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user