mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-05-18 22:25:41 -04:00
System: Interrupt execution when loading state and reset
This commit is contained in:
parent
417bf0c3bc
commit
440a1700c0
@ -1115,7 +1115,8 @@ void System::ResetSystem()
|
|||||||
InternalReset();
|
InternalReset();
|
||||||
ResetPerformanceCounters();
|
ResetPerformanceCounters();
|
||||||
ResetThrottler();
|
ResetThrottler();
|
||||||
Host::AddOSDMessage(TRANSLATE_STR("OSDMessage", "System reset."));
|
Host::AddIconOSDMessage("system_reset", ICON_FA_POWER_OFF, TRANSLATE_STR("OSDMessage", "System reset."),
|
||||||
|
Host::OSD_QUICK_DURATION);
|
||||||
}
|
}
|
||||||
|
|
||||||
void System::PauseSystem(bool paused)
|
void System::PauseSystem(bool paused)
|
||||||
@ -2232,6 +2233,7 @@ void System::InternalReset()
|
|||||||
s_frame_number = 1;
|
s_frame_number = 1;
|
||||||
s_internal_frame_number = 0;
|
s_internal_frame_number = 0;
|
||||||
TimingEvents::Reset();
|
TimingEvents::Reset();
|
||||||
|
InterruptExecution();
|
||||||
ResetPerformanceCounters();
|
ResetPerformanceCounters();
|
||||||
|
|
||||||
Achievements::ResetClient();
|
Achievements::ResetClient();
|
||||||
@ -2407,6 +2409,7 @@ bool System::LoadStateFromStream(ByteStream* state, bool update_display, bool ig
|
|||||||
if (s_state == State::Starting)
|
if (s_state == State::Starting)
|
||||||
s_state = State::Running;
|
s_state = State::Running;
|
||||||
|
|
||||||
|
InterruptExecution();
|
||||||
ResetPerformanceCounters();
|
ResetPerformanceCounters();
|
||||||
ResetThrottler();
|
ResetThrottler();
|
||||||
return true;
|
return true;
|
||||||
@ -4560,13 +4563,14 @@ bool System::LoadCheatList()
|
|||||||
|
|
||||||
if (cl->GetEnabledCodeCount() > 0)
|
if (cl->GetEnabledCodeCount() > 0)
|
||||||
{
|
{
|
||||||
Host::AddOSDMessage(
|
Host::AddIconOSDMessage(
|
||||||
|
"cheats_loaded", ICON_FA_EXCLAMATION_TRIANGLE,
|
||||||
fmt::format(TRANSLATE_FS("OSDMessage", "{} cheats are enabled. This may result in instability."),
|
fmt::format(TRANSLATE_FS("OSDMessage", "{} cheats are enabled. This may result in instability."),
|
||||||
cl->GetEnabledCodeCount()),
|
cl->GetEnabledCodeCount()),
|
||||||
30.0f);
|
Host::OSD_WARNING_DURATION);
|
||||||
}
|
}
|
||||||
|
|
||||||
System::SetCheatList(std::move(cl));
|
SetCheatList(std::move(cl));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -611,7 +611,7 @@ bool D3D11Device::BeginPresent(bool skip_present)
|
|||||||
if (!m_swap_chain)
|
if (!m_swap_chain)
|
||||||
{
|
{
|
||||||
// Note: Really slow on Intel...
|
// Note: Really slow on Intel...
|
||||||
m_context->Flush();
|
//m_context->Flush();
|
||||||
TrimTexturePool();
|
TrimTexturePool();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user