De-capitalized CountryCode

This commit is contained in:
Stevoisiak
2015-02-23 20:43:29 -05:00
parent df2f6d137e
commit 06cb85991e
10 changed files with 43 additions and 43 deletions

View File

@ -71,7 +71,7 @@ public:
};
// Generic Switch function for all volumes
IVolume::ECountry CountrySwitch(u8 CountryCode);
IVolume::ECountry CountrySwitch(u8 country_code);
u8 GetSysMenuRegion(u16 _TitleVersion);
} // namespace

View File

@ -12,9 +12,9 @@
// Increment CACHE_REVISION if the code below is modified (ISOFile.cpp & GameFile.cpp)
namespace DiscIO
{
IVolume::ECountry CountrySwitch(u8 CountryCode)
IVolume::ECountry CountrySwitch(u8 country_code)
{
switch (CountryCode)
switch (country_code)
{
// Region free - Uses European flag as placeholder
case 'A':
@ -68,8 +68,8 @@ IVolume::ECountry CountrySwitch(u8 CountryCode)
return IVolume::COUNTRY_TAIWAN;
default:
if (CountryCode > 'A') // Silently ignore IOS wads
WARN_LOG(DISCIO, "Unknown Country Code! %c", CountryCode);
if (country_code > 'A') // Silently ignore IOS wads
WARN_LOG(DISCIO, "Unknown Country Code! %c", country_code);
return IVolume::COUNTRY_UNKNOWN;
}
}

View File

@ -174,9 +174,9 @@ void CVolumeDirectory::SetUniqueID(const std::string& id)
IVolume::ECountry CVolumeDirectory::GetCountry() const
{
u8 CountryCode = m_diskHeader[3];
u8 country_code = m_diskHeader[3];
return CountrySwitch(CountryCode);
return CountrySwitch(country_code);
}
std::string CVolumeDirectory::GetMakerID() const

View File

@ -108,7 +108,7 @@ private:
u32 debug_flag;
u32 track_location;
u32 track_size;
u32 countrycode;
u32 country_code;
u32 unknown;
u32 unknown2;
@ -121,7 +121,7 @@ private:
debug_flag = 0;
track_location = 0;
track_size = 0;
countrycode = 0;
country_code = 0;
unknown = 0;
unknown2 = 0;
}

View File

@ -61,10 +61,10 @@ IVolume::ECountry CVolumeGC::GetCountry() const
if (!m_pReader)
return COUNTRY_UNKNOWN;
u8 CountryCode;
m_pReader->Read(3, 1, &CountryCode);
u8 country_code;
m_pReader->Read(3, 1, &country_code);
return CountrySwitch(CountryCode);
return CountrySwitch(country_code);
}
std::string CVolumeGC::GetMakerID() const

View File

@ -54,17 +54,17 @@ IVolume::ECountry CVolumeWAD::GetCountry() const
return COUNTRY_UNKNOWN;
// read the last digit of the titleID in the ticket
u8 CountryCode;
Read(m_tmd_offset + 0x0193, 1, &CountryCode);
u8 country_code;
Read(m_tmd_offset + 0x0193, 1, &country_code);
if (CountryCode == 2) // SYSMENU
if (country_code == 2) // SYSMENU
{
u16 titlever = 0;
Read(m_tmd_offset + 0x01dc, 2, (u8*)&titlever);
CountryCode = GetSysMenuRegion(Common::swap16(titlever));
country_code = GetSysMenuRegion(Common::swap16(titlever));
}
return CountrySwitch(CountryCode);
return CountrySwitch(country_code);
}
std::string CVolumeWAD::GetUniqueID() const

View File

@ -158,10 +158,10 @@ IVolume::ECountry CVolumeWiiCrypted::GetCountry() const
if (!m_pReader)
return COUNTRY_UNKNOWN;
u8 CountryCode;
m_pReader->Read(3, 1, &CountryCode);
u8 country_code;
m_pReader->Read(3, 1, &country_code);
return CountrySwitch(CountryCode);
return CountrySwitch(country_code);
}
std::string CVolumeWiiCrypted::GetMakerID() const