Merge pull request #1014 from RachelBryk/active-movie

Add an IsMovieActive function.
This commit is contained in:
skidau
2014-09-07 14:05:59 +10:00
10 changed files with 25 additions and 20 deletions

View File

@ -113,7 +113,7 @@ static bool IsMovieHeader(u8 magic[4])
std::string GetInputDisplay()
{
if (!IsPlayingInput() && !IsRecordingInput())
if (!IsMovieActive())
{
g_numPads = 0;
for (int i = 0; i < 4; i++)
@ -198,7 +198,7 @@ void Init()
for (auto& disp : g_InputDisplay)
disp.clear();
if (!IsPlayingInput() && !IsRecordingInput())
if (!IsMovieActive())
{
g_bRecordingFromSaveState = false;
g_rerecords = 0;
@ -273,7 +273,7 @@ void SetReadOnly(bool bEnabled)
void FrameSkipping()
{
// Frameskipping will desync movie playback
if (!IsPlayingInput() && !IsRecordingInput())
if (!IsMovieActive())
{
std::lock_guard<std::mutex> lk(cs_frameSkip);
@ -310,6 +310,11 @@ bool IsPlayingInput()
return (g_playMode == MODE_PLAYING);
}
bool IsMovieActive()
{
return g_playMode != MODE_NONE;
}
bool IsReadOnly()
{
return g_bReadOnly;