rename ROMSize to SNESROMSize (ROMSize name already in use!)

This commit is contained in:
dborth 2008-10-09 22:36:22 +00:00
parent eba96bba07
commit c92f97b4f6
4 changed files with 14 additions and 14 deletions

View File

@ -45,7 +45,7 @@ int selection;
char currentdir[MAXPATHLEN];
int maxfiles;
extern int screenheight;
unsigned long ROMSize = 0;
unsigned long SNESROMSize = 0;
int havedir = -1;
extern u64 dvddir;
@ -387,21 +387,21 @@ int FileSelector (int method)
{
case METHOD_SD:
case METHOD_USB:
ROMSize = LoadFATFile ((char *)Memory.ROM, 0);
SNESROMSize = LoadFATFile ((char *)Memory.ROM, 0);
break;
case METHOD_DVD:
dvddir = filelist[selection].offset;
dvddirlength = filelist[selection].length;
ROMSize = LoadDVDFile (Memory.ROM, 0);
SNESROMSize = LoadDVDFile (Memory.ROM, 0);
break;
case METHOD_SMB:
ROMSize = LoadSMBFile ((char *)Memory.ROM, 0);
SNESROMSize = LoadSMBFile ((char *)Memory.ROM, 0);
break;
}
if (ROMSize > 0)
if (SNESROMSize > 0)
{
Memory.LoadROM ("BLANK.SMC");
Memory.LoadSRAM ("BLANK");

View File

@ -36,7 +36,7 @@ extern int offset;
extern int selection;
extern char currentdir[MAXPATHLEN];
extern int maxfiles;
extern unsigned long ROMSize;
extern unsigned long SNESROMSize;
void AllocSaveBuffer();
void FreeSaveBuffer();

View File

@ -1051,7 +1051,7 @@ MainMenu (int selectedMenu)
int ret;
// disable game-specific menu items if a ROM isn't loaded
if (ROMSize == 0)
if (SNESROMSize == 0)
menuitems[2][0] = '\0';
else
sprintf (menuitems[2], "Game Menu");

View File

@ -235,16 +235,16 @@ main ()
if (memcmp ((char *) romptr, "SNESROM0", 8) == 0)
{
ROMSize = romptr[2];
SNESROMSize = romptr[2];
if(ROMSize > (1024*128) && ROMSize < (1024*1024*8))
if(SNESROMSize > (1024*128) && SNESROMSize < (1024*1024*8))
{
romptr = (int *) 0x81000020;
ARAMPut ((char *) romptr, (char *) AR_SNESROM, ROMSize);
ARAMPut ((char *) romptr, (char *) AR_SNESROM, SNESROMSize);
}
else // not a valid ROM size
{
ROMSize = 0;
SNESROMSize = 0;
}
}
#endif
@ -311,16 +311,16 @@ main ()
// from ARAM into main memory
#ifdef HW_DOL
if(ROMSize > 0)
if(SNESROMSize > 0)
{
ARAMFetchSlow( (char *)Memory.ROM, (char *)AR_SNESROM, ROMSize);
ARAMFetchSlow( (char *)Memory.ROM, (char *)AR_SNESROM, SNESROMSize);
Memory.LoadROM ("BLANK.SMC");
Memory.LoadSRAM ("BLANK");
}
#endif
// Get the user to load a ROM
while (ROMSize <= 0)
while (SNESROMSize <= 0)
{
MainMenu (selectedMenu);
}