Qt: use core display name if regular name is empty
This commit is contained in:
parent
51f968c557
commit
8d5f2ad1de
|
@ -1983,12 +1983,22 @@ void MainWindow::onPlaylistWidgetContextMenuRequested(const QPoint&)
|
||||||
QString key;
|
QString key;
|
||||||
const core_info_t *core = NULL;
|
const core_info_t *core = NULL;
|
||||||
QAction *action = NULL;
|
QAction *action = NULL;
|
||||||
|
QString name;
|
||||||
|
|
||||||
coreListIterator.next();
|
coreListIterator.next();
|
||||||
|
|
||||||
key = coreListIterator.key();
|
key = coreListIterator.key();
|
||||||
core = coreList.value(key);
|
core = coreList.value(key);
|
||||||
action = associateMenu->addAction(core->core_name);
|
|
||||||
|
if (string_is_empty(core->core_name))
|
||||||
|
name = core->display_name;
|
||||||
|
else
|
||||||
|
name = core->core_name;
|
||||||
|
|
||||||
|
if (name.isEmpty())
|
||||||
|
continue;
|
||||||
|
|
||||||
|
action = associateMenu->addAction(name);
|
||||||
action->setProperty("core_path", core->path);
|
action->setProperty("core_path", core->path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue