support loading of course edits

This commit is contained in:
Chris Danford
2005-07-31 05:41:32 +00:00
parent e5c1f09fa0
commit a2c439a17a
16 changed files with 814 additions and 552 deletions
+18
View File
@@ -5,6 +5,7 @@
#include "RageUtil_FileDB.h"
#include "RageLog.h"
#include "RageThreads.h"
#include "Foreach.h"
#include <cerrno>
#if defined(LINUX)
@@ -874,6 +875,23 @@ void GetDirListingRecursive( const CString &sDir, const CString &sMatch, CString
}
}
bool DeleteRecursive( const CString &sDir )
{
ASSERT( sDir.Right(1) == "/" );
vector<CString> vsFiles;
GetDirListing( sDir+"*", vsFiles, false, true );
FOREACH_CONST( CString, vsFiles, s )
{
if( IsADirectory(*s) )
DeleteRecursive( *s );
else
FILEMAN->Remove( *s );
}
return FILEMAN->Remove( sDir );
}
void FlushDirCache()
{
FILEMAN->FlushDirCache( "" );