From c19a0bdc5d1dbb756a8e80e05477851488220da2 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 23 Jan 2017 15:13:31 +0100 Subject: [PATCH] Simplify take_screenshot function --- tasks/task_screenshot.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/tasks/task_screenshot.c b/tasks/task_screenshot.c index 8687ab3b73..82fb6cecf7 100644 --- a/tasks/task_screenshot.c +++ b/tasks/task_screenshot.c @@ -384,9 +384,14 @@ static bool take_screenshot_choice(const char *name_base, bool savestate, bool take_screenshot(const char *name_base, bool silence) { - bool is_paused = runloop_ctl(RUNLOOP_CTL_IS_PAUSED, NULL); - bool is_idle = runloop_ctl(RUNLOOP_CTL_IS_IDLE, NULL); - bool ret = take_screenshot_choice(name_base, silence, is_paused, is_idle); + bool is_paused = false; + bool is_idle = false; + bool is_slowmotion = false; + bool ret = false; + + runloop_get_status(&is_paused, &is_idle, &is_slowmotion); + + ret = take_screenshot_choice(name_base, silence, is_paused, is_idle); if (is_paused && !is_idle) video_driver_cached_frame();