Merge pull request #5950 from ligfx/gamelistmodelfilenamefallback
GameListModel: fallback to file name if long name is empty
This commit is contained in:
commit
165a995cc4
|
@ -192,7 +192,6 @@ bool GameFile::TryLoadElfDol()
|
|||
return false;
|
||||
|
||||
m_revision = 0;
|
||||
m_long_names[DiscIO::Language::LANGUAGE_ENGLISH] = m_file_name;
|
||||
m_platform = DiscIO::Platform::ELF_DOL;
|
||||
m_region = DiscIO::Region::UNKNOWN_REGION;
|
||||
m_country = DiscIO::Country::COUNTRY_UNKNOWN;
|
||||
|
|
|
@ -76,7 +76,10 @@ QVariant GameListModel::data(const QModelIndex& index, int role) const
|
|||
Core::TitleDatabase::TitleType::Channel :
|
||||
Core::TitleDatabase::TitleType::Other));
|
||||
if (display_name.isEmpty())
|
||||
return game->GetLongName();
|
||||
display_name = game->GetLongName();
|
||||
|
||||
if (display_name.isEmpty())
|
||||
display_name = game->GetFileName();
|
||||
|
||||
return display_name;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue