REMOVED pause when inactive option as audio skips were inevitable when it was disabled.

REMOVED remains of generic flashcard option in GUI
This commit is contained in:
spacy51 2008-08-13 12:46:49 +00:00
parent dd40cfdc00
commit 86a59cdbcf
8 changed files with 7 additions and 65 deletions

View File

@ -140,7 +140,6 @@ struct {
{ "OptionsEmulatorAutoIPSPatch", ID_OPTIONS_EMULATOR_AUTOMATICALLYIPSPATCH },
{ "OptionsEmulatorAGBPrint", ID_OPTIONS_EMULATOR_AGBPRINT },
{ "OptionsEmulatorRTC", ID_OPTIONS_EMULATOR_REALTIMECLOCK },
{ "OptionsEmulatorGenericflashcard", ID_OPTIONS_EMULATOR_GENERICFLASHCARD },
{ "OptionsEmulatorRewindInterval", ID_OPTIONS_EMULATOR_REWINDINTERVAL },
{ "OptionsSoundOff", ID_OPTIONS_SOUND_OFF },
{ "OptionsSoundMute", ID_OPTIONS_SOUND_MUTE },

View File

@ -175,8 +175,6 @@ BEGIN_MESSAGE_MAP(MainWnd, CWnd)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_DISABLESTATUSMESSAGES, OnUpdateOptionsEmulatorDisablestatusmessages)
ON_COMMAND(ID_OPTIONS_EMULATOR_SYNCHRONIZE, OnOptionsEmulatorSynchronize)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_SYNCHRONIZE, OnUpdateOptionsEmulatorSynchronize)
ON_COMMAND(ID_OPTIONS_EMULATOR_PAUSEWHENINACTIVE, OnOptionsEmulatorPausewheninactive)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_PAUSEWHENINACTIVE, OnUpdateOptionsEmulatorPausewheninactive)
ON_COMMAND(ID_OPTIONS_EMULATOR_SPEEDUPTOGGLE, OnOptionsEmulatorSpeeduptoggle)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_SPEEDUPTOGGLE, OnUpdateOptionsEmulatorSpeeduptoggle)
ON_COMMAND(ID_OPTIONS_EMULATOR_AUTOMATICALLYIPSPATCH, OnOptionsEmulatorAutomaticallyipspatch)
@ -185,8 +183,6 @@ BEGIN_MESSAGE_MAP(MainWnd, CWnd)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_AGBPRINT, OnUpdateOptionsEmulatorAgbprint)
ON_COMMAND(ID_OPTIONS_EMULATOR_REALTIMECLOCK, OnOptionsEmulatorRealtimeclock)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_REALTIMECLOCK, OnUpdateOptionsEmulatorRealtimeclock)
ON_COMMAND(ID_OPTIONS_EMULATOR_GENERICFLASHCARD, OnOptionsEmulatorGenericflashcard)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_GENERICFLASHCARD, OnUpdateOptionsEmulatorGenericflashcard)
ON_COMMAND(ID_OPTIONS_EMULATOR_REWINDINTERVAL, OnOptionsEmulatorRewindinterval)
ON_COMMAND(ID_OPTIONS_EMULATOR_SAVETYPE_AUTOMATIC, OnOptionsEmulatorSavetypeAutomatic)
ON_UPDATE_COMMAND_UI(ID_OPTIONS_EMULATOR_SAVETYPE_AUTOMATIC, OnUpdateOptionsEmulatorSavetypeAutomatic)
@ -510,9 +506,6 @@ bool MainWnd::FileRun()
systemSaveUpdateCounter = SYSTEM_SAVE_NOT_UPDATED;
theApp.cartridgeType = type;
if(type == IMAGE_GB) {
genericflashcardEnable = theApp.winGenericflashcardEnable;
if(!gbLoadRom(theApp.szFile))
return false;
@ -1258,12 +1251,10 @@ void MainWnd::OnActivate(UINT nState, CWnd* pWndOther, BOOL bMinimized)
}
} else {
theApp.wasPaused = true;
if(theApp.pauseWhenInactive) {
if(emulating) {
if(emulating) {
soundPause();
}
theApp.active = a;
}
theApp.active = a;
memset(theApp.delta,255,sizeof(theApp.delta));
}

View File

@ -176,8 +176,6 @@ public:
afx_msg void OnUpdateOptionsEmulatorDisablestatusmessages(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorSynchronize();
afx_msg void OnUpdateOptionsEmulatorSynchronize(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorPausewheninactive();
afx_msg void OnUpdateOptionsEmulatorPausewheninactive(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorSpeeduptoggle();
afx_msg void OnUpdateOptionsEmulatorSpeeduptoggle(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorAutomaticallyipspatch();
@ -186,8 +184,6 @@ public:
afx_msg void OnUpdateOptionsEmulatorAgbprint(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorRealtimeclock();
afx_msg void OnUpdateOptionsEmulatorRealtimeclock(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorGenericflashcard();
afx_msg void OnUpdateOptionsEmulatorGenericflashcard(CCmdUI* pCmdUI);
afx_msg void OnOptionsEmulatorRewindinterval();
afx_msg void OnOptionsEmulatorSavetypeAutomatic();
afx_msg void OnUpdateOptionsEmulatorSavetypeAutomatic(CCmdUI* pCmdUI);

View File

@ -589,16 +589,6 @@ void MainWnd::OnUpdateOptionsEmulatorSynchronize(CCmdUI* pCmdUI)
pCmdUI->SetCheck(synchronize);
}
void MainWnd::OnOptionsEmulatorPausewheninactive()
{
theApp.pauseWhenInactive = !theApp.pauseWhenInactive;
}
void MainWnd::OnUpdateOptionsEmulatorPausewheninactive(CCmdUI* pCmdUI)
{
pCmdUI->SetCheck(theApp.pauseWhenInactive);
}
void MainWnd::OnOptionsEmulatorSpeeduptoggle()
{
theApp.speedupToggle = !theApp.speedupToggle;
@ -639,22 +629,6 @@ void MainWnd::OnUpdateOptionsEmulatorRealtimeclock(CCmdUI* pCmdUI)
pCmdUI->SetCheck(theApp.winRtcEnable);
}
void MainWnd::OnOptionsEmulatorGenericflashcard()
{
if(emulating && theApp.cartridgeType == IMAGE_GB)
theApp.winGenericflashcardEnable = !theApp.winGenericflashcardEnable;
}
void MainWnd::OnUpdateOptionsEmulatorGenericflashcard(CCmdUI* pCmdUI)
{
if(emulating && theApp.cartridgeType == IMAGE_GB)
pCmdUI->SetCheck(theApp.winGenericflashcardEnable);
else
pCmdUI->SetCheck(false);
pCmdUI->Enable(emulating && theApp.cartridgeType == IMAGE_GB);
}
void MainWnd::OnOptionsEmulatorRewindinterval()
{
RewindInterval dlg(theApp.rewindTimer/6);

View File

@ -272,7 +272,6 @@ VBA::VBA()
winGbBorderOn = 0;
winFlashSize = 0x20000;
winRtcEnable = false;
winGenericflashcardEnable = false;
winSaveType = 0;
rewindMemory = NULL;
rewindPos = 0;
@ -307,7 +306,6 @@ VBA::VBA()
iconic = false;
glFilter = 0;
regEnabled = false;
pauseWhenInactive = true;
speedupToggle = false;
winGbPrinterEnabled = false;
threadPriority = 2;
@ -1655,9 +1653,6 @@ void VBA::loadSettings()
else
gbSerialFunction = NULL;
pauseWhenInactive = regQueryDwordValue("pauseWhenInactive", 1) ?
true : false;
captureFormat = regQueryDwordValue("captureFormat", 0);
removeIntros = regQueryDwordValue("removeIntros", false) ? true : false;
@ -2641,8 +2636,6 @@ void VBA::saveSettings()
regSetDwordValue("gbPrinter", winGbPrinterEnabled);
regSetDwordValue("pauseWhenInactive", pauseWhenInactive);
regSetDwordValue("captureFormat", captureFormat);
regSetDwordValue("removeIntros", removeIntros);

View File

@ -134,7 +134,6 @@ class VBA : public CWinApp
int winGbBorderOn;
int winFlashSize;
bool winRtcEnable;
bool winGenericflashcardEnable;
int winSaveType;
char *rewindMemory;
int rewindPos;
@ -168,7 +167,6 @@ class VBA : public CWinApp
bool iconic;
int glFilter;
bool dinputKeyFocus;
bool pauseWhenInactive;
bool speedupToggle;
bool winGbPrinterEnabled;
int threadPriority;

View File

@ -1865,7 +1865,6 @@ BEGIN
END
MENUITEM "&Remove intros (GBA)", ID_OPTIONS_EMULATOR_REMOVEINTROSGBA
MENUITEM "Automatic IPS patching", ID_OPTIONS_EMULATOR_AUTOMATICALLYIPSPATCH
MENUITEM "Pause when inactive", ID_OPTIONS_EMULATOR_PAUSEWHENINACTIVE
MENUITEM "AGB Print", ID_OPTIONS_EMULATOR_AGBPRINT
MENUITEM "Real Time Clock", ID_OPTIONS_EMULATOR_REALTIMECLOCK
MENUITEM "&Game Overrides...", ID_OPTIONS_EMULATOR_GAMEOVERRIDES

View File

@ -640,10 +640,6 @@
#define ID_OPTIONS_VIDEO_FULLSCREENSTRETCHTOFIT 40089
#define ID_OPTIONS_EMULATOR_ASSOCIATE 40091
#define ID_OPTIONS_FILTER_DISABLEMMX 40093
#define ID_OPTIONS_1X 40096
#define ID_OPTIONS_2X 40097
#define ID_OPTIONS_3X 40098
#define ID_OPTIONS_4X 40099
#define ID_FILE_ROMINFORMATION 40100
#define ID_CHEATS_ADDCHEATCODE 40101
#define ID_OPTIONS_EMULATOR_DISABLESTATUSMESSAGES 40102
@ -663,7 +659,6 @@
#define ID_FILE_EXPORT_BATTERYFILE 40118
#define ID_OPTIONS_FILTER16BIT_PIXELATEEXPERIMENTAL 40121
#define ID_OPTIONS_FILTER16BIT_MOTIONBLUREXPERIMENTAL 40122
#define ID_OPTIONS_EMULATOR_PAUSEWHENINACTIVE 40124
#define ID_OPTIONS_SOUND_STARTRECORDING 40125
#define ID_OPTIONS_SOUND_STOPRECORDING 40126
#define ID_OPTIONS_VIDEO_LAYERS_BG0 40127
@ -769,7 +764,6 @@
#define ID_TOOLS_RECORD_STOPMOVIERECORDING 40252
#define ID_TOOLS_PLAY_STARTMOVIEPLAYING 40253
#define ID_TOOLS_PLAY_STOPMOVIEPLAYING 40254
#define ID_OPTIONS_EMULATOR_AUTOHIDEMENU 40255
#define ID_OPTIONS_GAMEBOY_BORDERAUTOMATIC 40256
#define ID_OPTIONS_EMULATOR_REWIND 40257
#define ID_TOOLS_REWIND 40258
@ -791,7 +785,6 @@
#define ID_OPTIONS_FILTER_LQ2X 40275
#define ID_OPTIONS_EMULATOR_GAMEOVERRIDES 40276
#define ID_HELP_GNUPUBLICLICENSE 40277
#define ID_OPTIONS_EMULATOR_GENERICFLASHCARD 40279
#define ID_OPTIONS_SOUND_HARDWAREACCELERATION 40281
#define ID_OPTIONS_VIDEO_FULLSCREEN1024X768 40282
#define ID_OPTIONS_VIDEO_FULLSCREEN1280X1024 40283
@ -869,13 +862,12 @@
#define ID_OUTPUTAPI_XAUDIO2CONFIG 40364
// Next default values for new objects
//
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 164
#define _APS_NEXT_CONTROL_VALUE 1288
#define _APS_NEXT_SYMED_VALUE 103
#define _APS_NEXT_COMMAND_VALUE 40365
#define _APS_NEXT_RESOURCE_VALUE 164
#define _APS_NEXT_COMMAND_VALUE 40365
#define _APS_NEXT_CONTROL_VALUE 1288
#define _APS_NEXT_SYMED_VALUE 103
#endif
#endif