06/6/2017

--Bug fixes
 -Fix crash when opening palette editor with a flame whose palette specifies no originating file.

--Code changes
 -Revert font changes, only use qss for these now.
This commit is contained in:
Person
2017-06-06 16:41:00 -07:00
parent 66a597df39
commit c194d708fd
7 changed files with 9 additions and 178 deletions

View File

@ -98,8 +98,12 @@ void PaletteEditor::SetPalette(const Palette<float>& palette)
if (!arrows.empty())
m_ColorPicker->SetColorPanelColor(arrows.begin()->second.Color());//Will emit PaletteChanged() if color changed...
QFileInfo info(QString::fromStdString(*palette.m_Filename.get()));
combo->setCurrentIndex(combo->findData(info.fileName(), Qt::DisplayRole));
if (palette.m_Filename.get())
{
QFileInfo info(QString::fromStdString(*palette.m_Filename.get()));
combo->setCurrentIndex(combo->findData(info.fileName(), Qt::DisplayRole));
}
EnablePaletteControls();
EmitPaletteChanged();//...So emit here just to be safe.
}