mirror of https://github.com/mgba-emu/mgba.git
Allow videos to be recorded from when a ROM is loaded, and end when a ROM is shut down
This commit is contained in:
parent
b51e72fcab
commit
1a09f93b27
|
@ -150,6 +150,9 @@ void Window::openVideoWindow() {
|
||||||
m_videoView = new VideoView();
|
m_videoView = new VideoView();
|
||||||
connect(m_videoView, SIGNAL(recordingStarted(GBAAVStream*)), m_controller, SLOT(setAVStream(GBAAVStream*)));
|
connect(m_videoView, SIGNAL(recordingStarted(GBAAVStream*)), m_controller, SLOT(setAVStream(GBAAVStream*)));
|
||||||
connect(m_videoView, SIGNAL(recordingStopped()), m_controller, SLOT(clearAVStream()), Qt::DirectConnection);
|
connect(m_videoView, SIGNAL(recordingStopped()), m_controller, SLOT(clearAVStream()), Qt::DirectConnection);
|
||||||
|
connect(m_controller, SIGNAL(gameStopped(GBAThread*)), m_videoView, SLOT(stopRecording()));
|
||||||
|
connect(m_controller, SIGNAL(gameStopped(GBAThread*)), m_videoView, SLOT(close()));
|
||||||
|
connect(this, SIGNAL(shutdown()), m_videoView, SLOT(close()));
|
||||||
}
|
}
|
||||||
m_videoView->show();
|
m_videoView->show();
|
||||||
}
|
}
|
||||||
|
@ -323,7 +326,6 @@ void Window::setupMenu(QMenuBar* menubar) {
|
||||||
QAction* recordOutput = new QAction(tr("Record output..."), fileMenu);
|
QAction* recordOutput = new QAction(tr("Record output..."), fileMenu);
|
||||||
recordOutput->setShortcut(tr("F11"));
|
recordOutput->setShortcut(tr("F11"));
|
||||||
connect(recordOutput, SIGNAL(triggered()), this, SLOT(openVideoWindow()));
|
connect(recordOutput, SIGNAL(triggered()), this, SLOT(openVideoWindow()));
|
||||||
m_gameActions.append(recordOutput);
|
|
||||||
fileMenu->addAction(recordOutput);
|
fileMenu->addAction(recordOutput);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue