From a880f2d57d673c4a436e1c44bb7989169a04fc5a Mon Sep 17 00:00:00 2001 From: Green Sky Date: Tue, 4 Jun 2024 19:05:35 +0200 Subject: [PATCH] prevent screensaver on android --- src/main.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main.cpp b/src/main.cpp index 62ad5b25..270b1699 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -30,9 +30,11 @@ int main(int argc, char** argv) { #endif // setup hints +#ifndef __ANDROID__ if (SDL_SetHint(SDL_HINT_VIDEO_ALLOW_SCREENSAVER, "1") != SDL_TRUE) { std::cerr << "Failed to set '" << SDL_HINT_VIDEO_ALLOW_SCREENSAVER << "' to 1\n"; } +#endif auto last_time_render = std::chrono::steady_clock::now(); auto last_time_tick = std::chrono::steady_clock::now();