Renamed: DiskProtect() to DiskGetProtect()

Added: DiskGetProtect()
This commit is contained in:
mpohoreski 2006-03-07 18:14:09 +00:00
parent 14b30f9478
commit 9141595031
2 changed files with 16 additions and 2 deletions

View File

@ -408,7 +408,20 @@ void DiskNotifyInvalidImage (LPCTSTR imagefilename,int error)
//=========================================================================== //===========================================================================
void DiskProtect( const int iDrive, const bool bWriteProtect ) bool DiskGetProtect( const int iDrive )
{
if (IsDriveValid( iDrive ))
{
Disk_t *pFloppy = &g_aFloppyDisk[ iDrive ];
if (pFloppy->writeprotected)
return true;
}
return false;
}
//===========================================================================
void DiskSetProtect( const int iDrive, const bool bWriteProtect )
{ {
if (IsDriveValid( iDrive )) if (IsDriveValid( iDrive ))
{ {

View File

@ -31,7 +31,8 @@ int DiskInsert (int,LPCTSTR,BOOL,BOOL);
BOOL DiskIsSpinning (); BOOL DiskIsSpinning ();
void DiskNotifyInvalidImage (LPCTSTR,int); void DiskNotifyInvalidImage (LPCTSTR,int);
void DiskReset (); void DiskReset ();
void DiskProtect( const int iDrive, const bool bWriteProtect ); bool DiskGetProtect( const int iDrive );
void DiskSetProtect( const int iDrive, const bool bWriteProtect );
void DiskSelect (int); void DiskSelect (int);
void DiskUpdatePosition (DWORD); void DiskUpdatePosition (DWORD);
bool DiskDriveSwap(); bool DiskDriveSwap();