updated the filesystemviewer. maybe someone can help and explain why the treectrl doesn't work for me in non-debug builds?

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@807 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Shawn Hoffman
2008-10-09 05:33:24 +00:00
parent 4001e11116
commit eb65601f90
9 changed files with 247 additions and 82 deletions

View File

@ -38,18 +38,6 @@ bool CVolumeGC::Read(u64 _Offset, u64 _Length, u8* _pBuffer) const
return m_pReader->Read(_Offset, _Length, _pBuffer);
}
std::string CVolumeGC::GetName() const
{
if (m_pReader == NULL)
return false;
char Name[128];
if (!Read(0x20, 0x60, (u8*)&Name))
return false;
return Name;
}
std::string CVolumeGC::GetUniqueID() const
{
static const std::string NO_UID("NO_UID");
@ -96,7 +84,7 @@ IVolume::ECountry CVolumeGC::GetCountry() const
case 'X':
country = COUNTRY_EUROPE;
break; // XIII <- uses X but is PAL rip
break; // XIII <- uses X but is PAL
case 'E':
country = COUNTRY_USA;
@ -119,6 +107,57 @@ IVolume::ECountry CVolumeGC::GetCountry() const
return(country);
}
std::string CVolumeGC::GetMakerID() const
{
if (m_pReader == NULL)
return false;
char makerID[3];
if (!Read(0x4, 0x2, (u8*)&makerID))
return false;
makerID[2] = 0;
return makerID;
}
std::string CVolumeGC::GetName() const
{
if (m_pReader == NULL)
return false;
char name[128];
if (!Read(0x20, 0x60, (u8*)&name))
return false;
return name;
}
u32 CVolumeGC::GetFSTSize() const
{
if (m_pReader == NULL)
return false;
u32 size;
if (!Read(0x428, 0x4, (u8*)&size))
return false;
return Common::swap32(size);
}
std::string CVolumeGC::GetApploaderDate() const
{
if (m_pReader == NULL)
return false;
char date[16];
if (!Read(0x2440, 0x10, (u8*)&date))
return false;
// Should be 0 already, but just in case
date[10] = 0;
return date;
}
u64 CVolumeGC::GetSize() const
{
if (m_pReader)