Qt: Rewind now shows the frame after rewinding

This commit is contained in:
Jeffrey Pfau 2015-04-12 20:22:32 -07:00
parent 293e0a9c9b
commit 2309898152
3 changed files with 4 additions and 0 deletions

View File

@ -395,6 +395,8 @@ void GameController::rewind(int states) {
GBARewind(&m_threadContext, states);
}
threadContinue();
emit rewound(&m_threadContext);
emit frameAvailable(m_drawContext);
}
void GameController::keyPressed(int key) {

View File

@ -85,6 +85,7 @@ signals:
void gameCrashed(const QString& errorMessage);
void gameFailed();
void stateLoaded(GBAThread*);
void rewound(GBAThread*);
void unimplementedBiosCall(int);
void luminanceValueChanged(int);

View File

@ -91,6 +91,7 @@ Window::Window(ConfigController* config, int playerId, QWidget* parent)
connect(m_controller, SIGNAL(gameStopped(GBAThread*)), m_display, SLOT(stopDrawing()));
connect(m_controller, SIGNAL(gameStopped(GBAThread*)), this, SLOT(gameStopped()));
connect(m_controller, SIGNAL(stateLoaded(GBAThread*)), m_display, SLOT(forceDraw()));
connect(m_controller, SIGNAL(rewound(GBAThread*)), m_display, SLOT(forceDraw()));
connect(m_controller, SIGNAL(gamePaused(GBAThread*)), m_display, SLOT(pauseDrawing()));
#ifndef Q_OS_MAC
connect(m_controller, SIGNAL(gamePaused(GBAThread*)), menuBar(), SLOT(show()));