[Companion] Do not run model wizard on a duplicated/copied model (fixes #4773); Replace existing file extension with .otx when first saving a converted bin/hex/eepe file (fixes #4772); Make sure no other models exist before setting first model as default (fix index 0 always being auto-selected).

This commit is contained in:
Max Paperno
2017-04-11 16:42:20 -04:00
parent de3c503e02
commit 350c3a6d44
3 changed files with 35 additions and 34 deletions
+1 -1
View File
@@ -177,7 +177,7 @@ QVariant TreeModel::data(const QModelIndex & index, int role) const
return item->data(index.column());
}
if (role == Qt::FontRole && item->getModelIndex() == (int)radioData->generalSettings.currModelIndex) {
if (role == Qt::FontRole && item->isModel() && item->getModelIndex() == (int)radioData->generalSettings.currModelIndex) {
QFont font;
font.setBold(true);
return font;