Core: SetOnStoppedCallback -> SetOnStateChangedCallback

This commit is contained in:
Michael M
2017-09-04 10:57:42 -07:00
parent 22a9a08b24
commit 8e805dcbf4
5 changed files with 25 additions and 11 deletions

View File

@ -530,8 +530,9 @@ void CFrame::InitializeCoreCallbacks()
});
// Warning: this gets called from the EmuThread
Core::SetOnStoppedCallback([this] {
AddPendingEvent(wxCommandEvent{wxEVT_HOST_COMMAND, IDM_STOPPED});
Core::SetOnStateChangedCallback([this](Core::State state) {
if (state == Core::State::Uninitialized)
AddPendingEvent(wxCommandEvent{wxEVT_HOST_COMMAND, IDM_STOPPED});
});
}