Changed playback pauseFrame variable and accessor functions to be static in PLAYBACK class so that they are thread safe for Qt GUI.
This commit is contained in:
parent
a673ee4a26
commit
e976ffac5b
|
@ -36,6 +36,7 @@ extern bool turbo;
|
|||
|
||||
// resources
|
||||
static char upperMarkerText[] = "Marker ";
|
||||
int PLAYBACK::pauseFrame = 0;
|
||||
|
||||
PLAYBACK::PLAYBACK()
|
||||
{
|
||||
|
|
|
@ -62,7 +62,7 @@ public:
|
|||
int getLastPosition(); // actually returns lost_position_frame-1
|
||||
void setLastPosition(int frame);
|
||||
|
||||
int getPauseFrame();
|
||||
static int getPauseFrame();
|
||||
int getFlashingPauseFrame();
|
||||
|
||||
void setProgressbar(int a, int b);
|
||||
|
@ -76,7 +76,7 @@ public:
|
|||
private:
|
||||
bool setPlaybackAboveOrToFrame(int frame, bool forceStateReload = false);
|
||||
|
||||
int pauseFrame;
|
||||
static int pauseFrame;
|
||||
int lastPositionFrame;
|
||||
bool lastPositionIsStable; // for when Greenzone invalidates several times, but the end of current segment must remain the same
|
||||
|
||||
|
|
|
@ -1200,7 +1200,7 @@ static void DoFun(int frameskip, int periodic_saves)
|
|||
{
|
||||
int runToFrameTarget;
|
||||
|
||||
runToFrameTarget = tasWin->playback.getPauseFrame();
|
||||
runToFrameTarget = PLAYBACK::getPauseFrame();
|
||||
|
||||
if ( runToFrameTarget >= 0)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue