allow mounting to the beginning of the mount list
This commit is contained in:
@@ -423,7 +423,7 @@ void RageFileManager::CreateDir( CString sDir )
|
|||||||
FILEMAN->Remove( sTempFile );
|
FILEMAN->Remove( sTempFile );
|
||||||
}
|
}
|
||||||
|
|
||||||
void RageFileManager::Mount( CString Type, CString Root, CString MountPoint )
|
void RageFileManager::Mount( CString Type, CString Root, CString MountPoint, bool bAddToEnd )
|
||||||
{
|
{
|
||||||
FixSlashesInPlace( Root );
|
FixSlashesInPlace( Root );
|
||||||
FixSlashesInPlace( MountPoint );
|
FixSlashesInPlace( MountPoint );
|
||||||
@@ -465,7 +465,7 @@ void RageFileManager::Mount( CString Type, CString Root, CString MountPoint )
|
|||||||
ld.MountPoint = MountPoint;
|
ld.MountPoint = MountPoint;
|
||||||
|
|
||||||
g_Mutex->Lock();
|
g_Mutex->Lock();
|
||||||
g_Drivers.push_back( ld );
|
g_Drivers.insert( bAddToEnd? g_Drivers.end():g_Drivers.begin(), ld );
|
||||||
CHECKPOINT;
|
CHECKPOINT;
|
||||||
g_Mountpoints->LoadFromDrivers( g_Drivers );
|
g_Mountpoints->LoadFromDrivers( g_Drivers );
|
||||||
CHECKPOINT;
|
CHECKPOINT;
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ public:
|
|||||||
int GetFileSizeInBytes( CString sPath );
|
int GetFileSizeInBytes( CString sPath );
|
||||||
int GetFileHash( CString sPath );
|
int GetFileHash( CString sPath );
|
||||||
|
|
||||||
void Mount( CString Type, CString RealPath, CString MountPoint );
|
void Mount( CString Type, CString RealPath, CString MountPoint, bool bAddToEnd = true );
|
||||||
void Unmount( CString Type, CString Root, CString MountPoint );
|
void Unmount( CString Type, CString Root, CString MountPoint );
|
||||||
|
|
||||||
/* Change the root of a filesystem. Only a couple drivers support this; it's
|
/* Change the root of a filesystem. Only a couple drivers support this; it's
|
||||||
|
|||||||
Reference in New Issue
Block a user