Fixed crashing bug that occurred if a WAnimParamsEditor is created for an MP1/2 property that has no valid animset
This commit is contained in:
parent
07d7f14dc7
commit
fa86d07b2d
|
@ -137,8 +137,9 @@ void WAnimParamsEditor::SetupUI()
|
||||||
mpCharComboBox = new QComboBox(this);
|
mpCharComboBox = new QComboBox(this);
|
||||||
CAnimSet *pSet = static_cast<CAnimSet*>(mParams.Resource());
|
CAnimSet *pSet = static_cast<CAnimSet*>(mParams.Resource());
|
||||||
|
|
||||||
for (u32 iChar = 0; iChar < pSet->getNodeCount(); iChar++)
|
if (pSet)
|
||||||
mpCharComboBox->addItem(QString::fromStdString(pSet->getNodeName(iChar)));
|
for (u32 iChar = 0; iChar < pSet->getNodeCount(); iChar++)
|
||||||
|
mpCharComboBox->addItem(QString::fromStdString(pSet->getNodeName(iChar)));
|
||||||
|
|
||||||
mpCharComboBox->setCurrentIndex(mParams.CharacterIndex());
|
mpCharComboBox->setCurrentIndex(mParams.CharacterIndex());
|
||||||
mpLabels[1] = new QLabel("Character", this);
|
mpLabels[1] = new QLabel("Character", this);
|
||||||
|
|
Loading…
Reference in New Issue