summaryrefslogtreecommitdiff
path: root/Source/Core/UICommon/GameFile.cpp
diff options
context:
space:
mode:
authorLéo Lam <leolino.lam@gmail.com>2018-03-31 14:37:26 +0200
committerGitHub <noreply@github.com>2018-03-31 14:37:26 +0200
commit329622120f23ec49471e520063b7eae2f3697164 (patch)
treece7c3ddfe353a5a66f1128cc2bebe558efbb1617 /Source/Core/UICommon/GameFile.cpp
parent127c2ce394f95cd713c09807c9112dc4dafa5b05 (diff)
parent4387432436c072944d7ee3e2554ac1cbad024441 (diff)
Merge pull request #6567 from JosJuice/discio-enums-case
DiscIO: Don't use all uppercase for enum values
Diffstat (limited to 'Source/Core/UICommon/GameFile.cpp')
-rw-r--r--Source/Core/UICommon/GameFile.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/Source/Core/UICommon/GameFile.cpp b/Source/Core/UICommon/GameFile.cpp
index e28ef3b274..47da5a69c5 100644
--- a/Source/Core/UICommon/GameFile.cpp
+++ b/Source/Core/UICommon/GameFile.cpp
@@ -48,9 +48,9 @@ const std::string& GameFile::Lookup(DiscIO::Language language,
return it->second;
// English tends to be a good fallback when the requested language isn't available
- if (language != DiscIO::Language::LANGUAGE_ENGLISH)
+ if (language != DiscIO::Language::English)
{
- it = strings.find(DiscIO::Language::LANGUAGE_ENGLISH);
+ it = strings.find(DiscIO::Language::English);
if (it != end)
return it->second;
}
@@ -70,8 +70,7 @@ GameFile::LookupUsingConfigLanguage(const std::map<DiscIO::Language, std::string
}
GameFile::GameFile(const std::string& path)
- : m_file_path(path), m_region(DiscIO::Region::UNKNOWN_REGION),
- m_country(DiscIO::Country::COUNTRY_UNKNOWN)
+ : m_file_path(path), m_region(DiscIO::Region::Unknown), m_country(DiscIO::Country::Unknown)
{
{
std::string name, extension;
@@ -113,7 +112,7 @@ GameFile::GameFile(const std::string& path)
{
m_valid = true;
m_file_size = File::GetSize(m_file_path);
- m_platform = DiscIO::Platform::ELF_DOL;
+ m_platform = DiscIO::Platform::ELFOrDOL;
m_blob_type = DiscIO::BlobType::DIRECTORY;
}
}
@@ -123,7 +122,7 @@ bool GameFile::IsValid() const
if (!m_valid)
return false;
- if (m_platform == DiscIO::Platform::WII_WAD && !IOS::ES::IsChannel(m_title_id))
+ if (m_platform == DiscIO::Platform::WiiWAD && !IOS::ES::IsChannel(m_title_id))
return false;
return true;
@@ -131,7 +130,7 @@ bool GameFile::IsValid() const
bool GameFile::CustomNameChanged(const Core::TitleDatabase& title_database)
{
- const auto type = m_platform == DiscIO::Platform::WII_WAD ?
+ const auto type = m_platform == DiscIO::Platform::WiiWAD ?
Core::TitleDatabase::TitleType::Channel :
Core::TitleDatabase::TitleType::Other;
m_pending.custom_name = title_database.GetTitleName(m_game_id, type);
@@ -273,7 +272,7 @@ std::vector<DiscIO::Language> GameFile::GetLanguages() const
std::string GameFile::GetUniqueIdentifier() const
{
- const DiscIO::Language lang = DiscIO::Language::LANGUAGE_ENGLISH;
+ const DiscIO::Language lang = DiscIO::Language::English;
std::vector<std::string> info;
if (!GetGameID().empty())
info.push_back(GetGameID());