citra_qt: Simplify movie recording code
The behavior shouldn't be changed.
This commit is contained in:
parent
1780f8b5b8
commit
d6b64f6b09
|
@ -1074,6 +1074,14 @@ void GMainWindow::BootGame(const QString& filename) {
|
||||||
ShowFullscreen();
|
ShowFullscreen();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (movie_record_on_start) {
|
||||||
|
Core::Movie::GetInstance().StartRecording(movie_record_path.toStdString(),
|
||||||
|
movie_record_author.toStdString());
|
||||||
|
movie_record_on_start = false;
|
||||||
|
movie_record_path.clear();
|
||||||
|
movie_record_author.clear();
|
||||||
|
}
|
||||||
|
|
||||||
if (video_dumping_on_start) {
|
if (video_dumping_on_start) {
|
||||||
Layout::FramebufferLayout layout{
|
Layout::FramebufferLayout layout{
|
||||||
Layout::FrameLayoutFromResolutionScale(VideoCore::GetResolutionScaleFactor())};
|
Layout::FrameLayoutFromResolutionScale(VideoCore::GetResolutionScaleFactor())};
|
||||||
|
@ -1540,14 +1548,6 @@ void GMainWindow::OnMenuRecentFile() {
|
||||||
void GMainWindow::OnStartGame() {
|
void GMainWindow::OnStartGame() {
|
||||||
Camera::QtMultimediaCameraHandler::ResumeCameras();
|
Camera::QtMultimediaCameraHandler::ResumeCameras();
|
||||||
|
|
||||||
if (movie_record_on_start) {
|
|
||||||
Core::Movie::GetInstance().StartRecording(movie_record_path.toStdString(),
|
|
||||||
movie_record_author.toStdString());
|
|
||||||
movie_record_on_start = false;
|
|
||||||
movie_record_path.clear();
|
|
||||||
movie_record_author.clear();
|
|
||||||
}
|
|
||||||
|
|
||||||
PreventOSSleep();
|
PreventOSSleep();
|
||||||
|
|
||||||
emu_thread->SetRunning(true);
|
emu_thread->SetRunning(true);
|
||||||
|
@ -1853,15 +1853,12 @@ void GMainWindow::OnRecordMovie() {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (emulation_running) {
|
movie_record_on_start = true;
|
||||||
// Restart game
|
movie_record_path = dialog.GetPath();
|
||||||
|
movie_record_author = dialog.GetAuthor();
|
||||||
|
|
||||||
|
if (emulation_running) { // Restart game
|
||||||
BootGame(QString(game_path));
|
BootGame(QString(game_path));
|
||||||
Core::Movie::GetInstance().StartRecording(dialog.GetPath().toStdString(),
|
|
||||||
dialog.GetAuthor().toStdString());
|
|
||||||
} else {
|
|
||||||
movie_record_on_start = true;
|
|
||||||
movie_record_path = dialog.GetPath();
|
|
||||||
movie_record_author = dialog.GetAuthor();
|
|
||||||
}
|
}
|
||||||
ui->action_Close_Movie->setEnabled(true);
|
ui->action_Close_Movie->setEnabled(true);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue