summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAmeer J <52414509+ameerj@users.noreply.github.com>2021-08-10 05:49:48 +0200
committerGitHub <noreply@github.com>2021-08-10 05:49:48 +0200
commit9fbe188c01c409f68e805d494140d7740d00cbe0 (patch)
tree66096243f759651e2d276bcbf4c8f8a0cd472c1a /src
parentMerge pull request #6823 from yzct12345/memory-cleanup (diff)
parentmain: Avoid stopping emulation when taking a screenshot (diff)
downloadyuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.tar
yuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.tar.gz
yuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.tar.bz2
yuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.tar.lz
yuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.tar.xz
yuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.tar.zst
yuzu-9fbe188c01c409f68e805d494140d7740d00cbe0.zip
Diffstat (limited to 'src')
-rw-r--r--src/yuzu/main.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp
index 9544f0fb0..5940e0cfd 100644
--- a/src/yuzu/main.cpp
+++ b/src/yuzu/main.cpp
@@ -2814,8 +2814,6 @@ void GMainWindow::OnToggleFilterBar() {
}
void GMainWindow::OnCaptureScreenshot() {
- OnPauseGame();
-
const u64 title_id = Core::System::GetInstance().CurrentProcess()->GetTitleID();
const auto screenshot_path =
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::ScreenshotsDir));
@@ -2827,23 +2825,22 @@ void GMainWindow::OnCaptureScreenshot() {
.arg(date);
if (!Common::FS::CreateDir(screenshot_path.toStdString())) {
- OnStartGame();
return;
}
#ifdef _WIN32
if (UISettings::values.enable_screenshot_save_as) {
+ OnPauseGame();
filename = QFileDialog::getSaveFileName(this, tr("Capture Screenshot"), filename,
tr("PNG Image (*.png)"));
+ OnStartGame();
if (filename.isEmpty()) {
- OnStartGame();
return;
}
}
#endif
render_window->CaptureScreenshot(UISettings::values.screenshot_resolution_factor.GetValue(),
filename);
- OnStartGame();
}
// TODO: Written 2020-10-01: Remove per-game config migration code when it is irrelevant