System: Fix vsync resetting on pause and fast forward on boot

This commit is contained in:
Connor McLaughlin 2022-08-05 17:09:44 +10:00
parent fd3de15589
commit 8f314c8d49
2 changed files with 4 additions and 4 deletions

View file

@ -931,6 +931,7 @@ void System::PauseSystem(bool paused)
else
{
Host::OnSystemResumed();
g_host_display->SetVSync(ShouldUseVSync());
ResetPerformanceCounters();
ResetThrottler();
}
@ -1252,6 +1253,8 @@ bool System::Initialize(bool force_software_renderer)
s_throttle_frequency = 60.0f;
s_frame_period = 0;
s_next_frame_time = 0;
m_turbo_enabled = false;
m_fast_forward_enabled = false;
s_average_frame_time_accumulator = 0.0f;
s_worst_frame_time_accumulator = 0.0f;

View file

@ -475,10 +475,7 @@ void FullscreenUI::OnSystemPaused()
void FullscreenUI::OnSystemResumed()
{
if (!IsInitialized())
return;
g_host_display->SetVSync(System::ShouldUseVSync());
// noop
}
void FullscreenUI::OnSystemDestroyed()