Add an option to pause on the last frame of a movie.
This commit is contained in:
parent
ab48e1154b
commit
35e5a1e592
|
@ -131,6 +131,7 @@ void SConfig::SaveSettings()
|
||||||
|
|
||||||
// General
|
// General
|
||||||
ini.Set("General", "LastFilename", m_LastFilename);
|
ini.Set("General", "LastFilename", m_LastFilename);
|
||||||
|
ini.Set("General", "PauseMovie", m_pauseMovie);
|
||||||
|
|
||||||
// ISO folders
|
// ISO folders
|
||||||
// clear removed folders
|
// clear removed folders
|
||||||
|
@ -260,6 +261,7 @@ void SConfig::LoadSettings()
|
||||||
// General
|
// General
|
||||||
{
|
{
|
||||||
ini.Get("General", "LastFilename", &m_LastFilename);
|
ini.Get("General", "LastFilename", &m_LastFilename);
|
||||||
|
ini.Get("General", "PauseMovie", &m_pauseMovie, false);
|
||||||
|
|
||||||
m_ISOFolder.clear();
|
m_ISOFolder.clear();
|
||||||
int numGCMPaths;
|
int numGCMPaths;
|
||||||
|
|
|
@ -75,6 +75,7 @@ struct SConfig : NonCopyable
|
||||||
bool m_ListKorea;
|
bool m_ListKorea;
|
||||||
bool m_ListTaiwan;
|
bool m_ListTaiwan;
|
||||||
bool m_ListUnknown;
|
bool m_ListUnknown;
|
||||||
|
bool m_pauseMovie;
|
||||||
|
|
||||||
SysConf* m_SYSCONF;
|
SysConf* m_SYSCONF;
|
||||||
|
|
||||||
|
|
|
@ -92,6 +92,10 @@ std::string GetInputDisplay()
|
||||||
|
|
||||||
void FrameUpdate()
|
void FrameUpdate()
|
||||||
{
|
{
|
||||||
|
if (SConfig::GetInstance().m_pauseMovie && IsPlayingInput() && g_currentInputCount == g_totalInputCount -1)
|
||||||
|
{
|
||||||
|
Core::SetState(Core::CORE_PAUSE);
|
||||||
|
}
|
||||||
g_currentFrame++;
|
g_currentFrame++;
|
||||||
if(!g_bPolled)
|
if(!g_bPolled)
|
||||||
g_currentLagCount++;
|
g_currentLagCount++;
|
||||||
|
|
|
@ -244,6 +244,7 @@ EVT_MENU(IDM_PLAYRECORD, CFrame::OnPlayRecording)
|
||||||
EVT_MENU(IDM_RECORDEXPORT, CFrame::OnRecordExport)
|
EVT_MENU(IDM_RECORDEXPORT, CFrame::OnRecordExport)
|
||||||
EVT_MENU(IDM_RECORDREADONLY, CFrame::OnRecordReadOnly)
|
EVT_MENU(IDM_RECORDREADONLY, CFrame::OnRecordReadOnly)
|
||||||
EVT_MENU(IDM_TASINPUT, CFrame::OnTASInput)
|
EVT_MENU(IDM_TASINPUT, CFrame::OnTASInput)
|
||||||
|
EVT_MENU(IDM_TOGGLE_PAUSEMOVIE, CFrame::OnTogglePauseMovie)
|
||||||
EVT_MENU(IDM_FRAMESTEP, CFrame::OnFrameStep)
|
EVT_MENU(IDM_FRAMESTEP, CFrame::OnFrameStep)
|
||||||
EVT_MENU(IDM_SCREENSHOT, CFrame::OnScreenshot)
|
EVT_MENU(IDM_SCREENSHOT, CFrame::OnScreenshot)
|
||||||
EVT_MENU(wxID_PREFERENCES, CFrame::OnConfigMain)
|
EVT_MENU(wxID_PREFERENCES, CFrame::OnConfigMain)
|
||||||
|
|
|
@ -297,6 +297,7 @@ private:
|
||||||
void OnRecordExport(wxCommandEvent& event);
|
void OnRecordExport(wxCommandEvent& event);
|
||||||
void OnRecordReadOnly(wxCommandEvent& event);
|
void OnRecordReadOnly(wxCommandEvent& event);
|
||||||
void OnTASInput(wxCommandEvent& event);
|
void OnTASInput(wxCommandEvent& event);
|
||||||
|
void OnTogglePauseMovie(wxCommandEvent& event);
|
||||||
void OnChangeDisc(wxCommandEvent& event);
|
void OnChangeDisc(wxCommandEvent& event);
|
||||||
void OnScreenshot(wxCommandEvent& event);
|
void OnScreenshot(wxCommandEvent& event);
|
||||||
void OnActive(wxActivateEvent& event);
|
void OnActive(wxActivateEvent& event);
|
||||||
|
|
|
@ -142,6 +142,8 @@ void CFrame::CreateMenu()
|
||||||
emulationMenu->Append(IDM_RECORDEXPORT, GetMenuLabel(HK_EXPORT_RECORDING));
|
emulationMenu->Append(IDM_RECORDEXPORT, GetMenuLabel(HK_EXPORT_RECORDING));
|
||||||
emulationMenu->Append(IDM_RECORDREADONLY, GetMenuLabel(HK_READ_ONLY_MODE), wxEmptyString, wxITEM_CHECK);
|
emulationMenu->Append(IDM_RECORDREADONLY, GetMenuLabel(HK_READ_ONLY_MODE), wxEmptyString, wxITEM_CHECK);
|
||||||
emulationMenu->Append(IDM_TASINPUT, _("TAS Input"));
|
emulationMenu->Append(IDM_TASINPUT, _("TAS Input"));
|
||||||
|
emulationMenu->AppendCheckItem(IDM_TOGGLE_PAUSEMOVIE, _("Pause at end of movie"));
|
||||||
|
emulationMenu->Check(IDM_TOGGLE_PAUSEMOVIE, SConfig::GetInstance().m_pauseMovie);
|
||||||
emulationMenu->Check(IDM_RECORDREADONLY, true);
|
emulationMenu->Check(IDM_RECORDREADONLY, true);
|
||||||
emulationMenu->AppendSeparator();
|
emulationMenu->AppendSeparator();
|
||||||
|
|
||||||
|
@ -702,6 +704,11 @@ void CFrame::OnTASInput(wxCommandEvent& event)
|
||||||
g_TASInputDlg->Show(true);
|
g_TASInputDlg->Show(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void CFrame::OnTogglePauseMovie(wxCommandEvent& WXUNUSED (event))
|
||||||
|
{
|
||||||
|
SConfig::GetInstance().m_pauseMovie = !SConfig::GetInstance().m_pauseMovie;
|
||||||
|
SConfig::GetInstance().SaveSettings();
|
||||||
|
}
|
||||||
void CFrame::OnFrameStep(wxCommandEvent& event)
|
void CFrame::OnFrameStep(wxCommandEvent& event)
|
||||||
{
|
{
|
||||||
bool wasPaused = (Core::GetState() == Core::CORE_PAUSE);
|
bool wasPaused = (Core::GetState() == Core::CORE_PAUSE);
|
||||||
|
|
|
@ -80,6 +80,7 @@ enum
|
||||||
IDM_RECORDEXPORT,
|
IDM_RECORDEXPORT,
|
||||||
IDM_RECORDREADONLY,
|
IDM_RECORDREADONLY,
|
||||||
IDM_TASINPUT,
|
IDM_TASINPUT,
|
||||||
|
IDM_TOGGLE_PAUSEMOVIE,
|
||||||
IDM_FRAMESTEP,
|
IDM_FRAMESTEP,
|
||||||
IDM_SCREENSHOT,
|
IDM_SCREENSHOT,
|
||||||
IDM_BROWSE,
|
IDM_BROWSE,
|
||||||
|
|
Loading…
Reference in New Issue