This commit is contained in:
parent
8201eb85b3
commit
3a5aac88f8
|
@ -107,6 +107,8 @@ BEGIN_MESSAGE_MAP(MainWnd, CWnd)
|
||||||
ON_COMMAND(ID_OPTIONS_FRAMESKIP_THROTTLE_150, OnOptionsFrameskipThrottle150)
|
ON_COMMAND(ID_OPTIONS_FRAMESKIP_THROTTLE_150, OnOptionsFrameskipThrottle150)
|
||||||
ON_COMMAND(ID_OPTIONS_FRAMESKIP_THROTTLE_200, OnOptionsFrameskipThrottle200)
|
ON_COMMAND(ID_OPTIONS_FRAMESKIP_THROTTLE_200, OnOptionsFrameskipThrottle200)
|
||||||
ON_COMMAND(ID_OPTIONS_FRAMESKIP_THROTTLE_OTHER, OnOptionsFrameskipThrottleOther)
|
ON_COMMAND(ID_OPTIONS_FRAMESKIP_THROTTLE_OTHER, OnOptionsFrameskipThrottleOther)
|
||||||
|
ON_COMMAND(ID_OPTIONS_FRAMESKIP_AUTOMATIC, OnOptionsFrameskipAutomatic)
|
||||||
|
ON_UPDATE_COMMAND_UI(ID_OPTIONS_FRAMESKIP_AUTOMATIC, OnUpdateOptionsFrameskipAutomatic)
|
||||||
ON_UPDATE_COMMAND_UI(ID_OPTIONS_VIDEO_FRAMESKIP_0, OnUpdateOptionsVideoFrameskip0)
|
ON_UPDATE_COMMAND_UI(ID_OPTIONS_VIDEO_FRAMESKIP_0, OnUpdateOptionsVideoFrameskip0)
|
||||||
ON_UPDATE_COMMAND_UI(ID_OPTIONS_VIDEO_FRAMESKIP_1, OnUpdateOptionsVideoFrameskip1)
|
ON_UPDATE_COMMAND_UI(ID_OPTIONS_VIDEO_FRAMESKIP_1, OnUpdateOptionsVideoFrameskip1)
|
||||||
ON_UPDATE_COMMAND_UI(ID_OPTIONS_VIDEO_FRAMESKIP_2, OnUpdateOptionsVideoFrameskip2)
|
ON_UPDATE_COMMAND_UI(ID_OPTIONS_VIDEO_FRAMESKIP_2, OnUpdateOptionsVideoFrameskip2)
|
||||||
|
|
|
@ -111,6 +111,8 @@ protected:
|
||||||
afx_msg void OnOptionsFrameskipThrottle150();
|
afx_msg void OnOptionsFrameskipThrottle150();
|
||||||
afx_msg void OnOptionsFrameskipThrottle200();
|
afx_msg void OnOptionsFrameskipThrottle200();
|
||||||
afx_msg void OnOptionsFrameskipThrottleOther();
|
afx_msg void OnOptionsFrameskipThrottleOther();
|
||||||
|
afx_msg void OnOptionsFrameskipAutomatic();
|
||||||
|
afx_msg void OnUpdateOptionsFrameskipAutomatic(CCmdUI* pCmdUI);
|
||||||
afx_msg void OnUpdateOptionsVideoFrameskip0(CCmdUI* pCmdUI);
|
afx_msg void OnUpdateOptionsVideoFrameskip0(CCmdUI* pCmdUI);
|
||||||
afx_msg void OnUpdateOptionsVideoFrameskip1(CCmdUI* pCmdUI);
|
afx_msg void OnUpdateOptionsVideoFrameskip1(CCmdUI* pCmdUI);
|
||||||
afx_msg void OnUpdateOptionsVideoFrameskip2(CCmdUI* pCmdUI);
|
afx_msg void OnUpdateOptionsVideoFrameskip2(CCmdUI* pCmdUI);
|
||||||
|
|
|
@ -37,9 +37,9 @@
|
||||||
void MainWnd::OnOptionsFrameskipThrottleNothrottle()
|
void MainWnd::OnOptionsFrameskipThrottleNothrottle()
|
||||||
{
|
{
|
||||||
theApp.updateThrottle( 0 ); // disable
|
theApp.updateThrottle( 0 ); // disable
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainWnd::OnUpdateOptionsFrameskipThrottleNothrottle(CCmdUI* pCmdUI)
|
void MainWnd::OnUpdateOptionsFrameskipThrottleNothrottle(CCmdUI* pCmdUI)
|
||||||
{
|
{
|
||||||
pCmdUI->SetCheck( theApp.throttle == 0 );
|
pCmdUI->SetCheck( theApp.throttle == 0 );
|
||||||
|
@ -49,9 +49,9 @@ void MainWnd::OnUpdateOptionsFrameskipThrottleNothrottle(CCmdUI* pCmdUI)
|
||||||
void MainWnd::OnOptionsFrameskipThrottle25()
|
void MainWnd::OnOptionsFrameskipThrottle25()
|
||||||
{
|
{
|
||||||
theApp.updateThrottle( 25 );
|
theApp.updateThrottle( 25 );
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainWnd::OnUpdateOptionsFrameskipThrottle25(CCmdUI* pCmdUI)
|
void MainWnd::OnUpdateOptionsFrameskipThrottle25(CCmdUI* pCmdUI)
|
||||||
{
|
{
|
||||||
pCmdUI->SetCheck( theApp.throttle == 25 );
|
pCmdUI->SetCheck( theApp.throttle == 25 );
|
||||||
|
@ -61,9 +61,9 @@ void MainWnd::OnUpdateOptionsFrameskipThrottle25(CCmdUI* pCmdUI)
|
||||||
void MainWnd::OnOptionsFrameskipThrottle50()
|
void MainWnd::OnOptionsFrameskipThrottle50()
|
||||||
{
|
{
|
||||||
theApp.updateThrottle( 50 );
|
theApp.updateThrottle( 50 );
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainWnd::OnUpdateOptionsFrameskipThrottle50(CCmdUI* pCmdUI)
|
void MainWnd::OnUpdateOptionsFrameskipThrottle50(CCmdUI* pCmdUI)
|
||||||
{
|
{
|
||||||
pCmdUI->SetCheck( theApp.throttle == 50 );
|
pCmdUI->SetCheck( theApp.throttle == 50 );
|
||||||
|
@ -73,9 +73,9 @@ void MainWnd::OnUpdateOptionsFrameskipThrottle50(CCmdUI* pCmdUI)
|
||||||
void MainWnd::OnOptionsFrameskipThrottle100()
|
void MainWnd::OnOptionsFrameskipThrottle100()
|
||||||
{
|
{
|
||||||
theApp.updateThrottle( 100 );
|
theApp.updateThrottle( 100 );
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainWnd::OnUpdateOptionsFrameskipThrottle100(CCmdUI* pCmdUI)
|
void MainWnd::OnUpdateOptionsFrameskipThrottle100(CCmdUI* pCmdUI)
|
||||||
{
|
{
|
||||||
pCmdUI->SetCheck( theApp.throttle == 100 );
|
pCmdUI->SetCheck( theApp.throttle == 100 );
|
||||||
|
@ -85,9 +85,9 @@ void MainWnd::OnUpdateOptionsFrameskipThrottle100(CCmdUI* pCmdUI)
|
||||||
void MainWnd::OnOptionsFrameskipThrottle150()
|
void MainWnd::OnOptionsFrameskipThrottle150()
|
||||||
{
|
{
|
||||||
theApp.updateThrottle( 150 );
|
theApp.updateThrottle( 150 );
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainWnd::OnUpdateOptionsFrameskipThrottle150(CCmdUI* pCmdUI)
|
void MainWnd::OnUpdateOptionsFrameskipThrottle150(CCmdUI* pCmdUI)
|
||||||
{
|
{
|
||||||
pCmdUI->SetCheck( theApp.throttle == 150 );
|
pCmdUI->SetCheck( theApp.throttle == 150 );
|
||||||
|
@ -97,9 +97,9 @@ void MainWnd::OnUpdateOptionsFrameskipThrottle150(CCmdUI* pCmdUI)
|
||||||
void MainWnd::OnOptionsFrameskipThrottle200()
|
void MainWnd::OnOptionsFrameskipThrottle200()
|
||||||
{
|
{
|
||||||
theApp.updateThrottle( 200 );
|
theApp.updateThrottle( 200 );
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainWnd::OnUpdateOptionsFrameskipThrottle200(CCmdUI* pCmdUI)
|
void MainWnd::OnUpdateOptionsFrameskipThrottle200(CCmdUI* pCmdUI)
|
||||||
{
|
{
|
||||||
pCmdUI->SetCheck( theApp.throttle == 200 );
|
pCmdUI->SetCheck( theApp.throttle == 200 );
|
||||||
|
@ -113,6 +113,7 @@ void MainWnd::OnOptionsFrameskipThrottleOther()
|
||||||
|
|
||||||
if( v ) {
|
if( v ) {
|
||||||
theApp.updateThrottle( v );
|
theApp.updateThrottle( v );
|
||||||
|
theApp.autoFrameSkip = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -128,6 +129,23 @@ void MainWnd::OnUpdateOptionsFrameskipThrottleOther(CCmdUI* pCmdUI)
|
||||||
( theApp.throttle != 200 ) );
|
( theApp.throttle != 200 ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MainWnd::OnOptionsFrameskipAutomatic()
|
||||||
|
{
|
||||||
|
theApp.autoFrameSkip = !theApp.autoFrameSkip;
|
||||||
|
if(!theApp.autoFrameSkip && emulating)
|
||||||
|
theApp.updateFrameSkip();
|
||||||
|
else
|
||||||
|
{
|
||||||
|
theApp.throttle = false;
|
||||||
|
frameSkip = 0;
|
||||||
|
systemFrameSkip = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void MainWnd::OnUpdateOptionsFrameskipAutomatic(CCmdUI* pCmdUI)
|
||||||
|
{
|
||||||
|
pCmdUI->SetCheck(theApp.autoFrameSkip);
|
||||||
|
}
|
||||||
|
|
||||||
BOOL MainWnd::OnOptionsFrameskip(UINT nID)
|
BOOL MainWnd::OnOptionsFrameskip(UINT nID)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1115,6 +1115,7 @@ void system10Frames(int rate)
|
||||||
}
|
}
|
||||||
|
|
||||||
theApp.wasPaused = false;
|
theApp.wasPaused = false;
|
||||||
|
theApp.autoFrameSkipLastTime = time;
|
||||||
|
|
||||||
#ifdef LOG_PERFORMANCE
|
#ifdef LOG_PERFORMANCE
|
||||||
if( systemSpeedCounter >= PERFORMANCE_INTERVAL ) {
|
if( systemSpeedCounter >= PERFORMANCE_INTERVAL ) {
|
||||||
|
@ -1362,6 +1363,8 @@ void VBA::loadSettings()
|
||||||
if(gbFrameSkip < 0 || gbFrameSkip > 9)
|
if(gbFrameSkip < 0 || gbFrameSkip > 9)
|
||||||
gbFrameSkip = 0;
|
gbFrameSkip = 0;
|
||||||
|
|
||||||
|
autoFrameSkip = regQueryDwordValue("autoFrameSkip", FALSE) ? TRUE : FALSE;
|
||||||
|
|
||||||
vsync = regQueryDwordValue("vsync", false) ? true : false ;
|
vsync = regQueryDwordValue("vsync", false) ? true : false ;
|
||||||
synchronize = regQueryDwordValue("synchronize", 1) ? true : false;
|
synchronize = regQueryDwordValue("synchronize", 1) ? true : false;
|
||||||
fullScreenStretch = regQueryDwordValue("stretch", 0) ? true : false;
|
fullScreenStretch = regQueryDwordValue("stretch", 0) ? true : false;
|
||||||
|
|
Loading…
Reference in New Issue