CString -> RString

This commit is contained in:
Chris Danford
2006-01-22 01:00:06 +00:00
parent 870ed267fc
commit 7f821e8cfc
578 changed files with 3943 additions and 3946 deletions
+7 -7
View File
@@ -24,7 +24,7 @@
void MsdFile::AddParam( char *buf, int len )
{
values.back().params.push_back(CString(buf, len));
values.back().params.push_back(RString(buf, len));
}
void MsdFile::AddValue() /* (no extra charge) */
@@ -121,7 +121,7 @@ void MsdFile::ReadBuf( char *buf, int len )
}
// returns true if successful, false otherwise
bool MsdFile::ReadFile( CString sNewPath )
bool MsdFile::ReadFile( RString sNewPath )
{
error = "";
@@ -134,7 +134,7 @@ bool MsdFile::ReadFile( CString sNewPath )
}
// allocate a string to hold the file
CString FileString;
RString FileString;
FileString.reserve( f.GetFileSize() );
int iBytesRead = f.Read( FileString );
@@ -149,7 +149,7 @@ bool MsdFile::ReadFile( CString sNewPath )
return true;
}
void MsdFile::ReadFromString( const CString &sString )
void MsdFile::ReadFromString( const RString &sString )
{
/* Be careful. ReadBuf modifies the buffer given to it. */
char *pCopy = new char[sString.size()];
@@ -158,10 +158,10 @@ void MsdFile::ReadFromString( const CString &sString )
delete [] pCopy;
}
CString MsdFile::GetParam(unsigned val, unsigned par) const
RString MsdFile::GetParam(unsigned val, unsigned par) const
{
if(val >= GetNumValues()) return CString();
if(par >= GetNumParams(val)) return CString();
if(val >= GetNumValues()) return RString();
if(par >= GetNumParams(val)) return RString();
return values[val].params[par];
}