From a039b87348157bb4cb618b132f236ba66ff56ff9 Mon Sep 17 00:00:00 2001 From: cuu Date: Sat, 23 Feb 2019 03:42:01 +0800 Subject: [PATCH] fix fullscreen --- src/studio.c | 14 +++++++++----- src/system.h | 1 + src/system/sdlgpu.c | 2 ++ 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/src/studio.c b/src/studio.c index a93152d..2b80ec0 100644 --- a/src/studio.c +++ b/src/studio.c @@ -1875,11 +1875,6 @@ Studio* studioInit(s32 argc, char **argv, s32 samplerate, const char* folder, Sy setStudioMode(TIC_CONSOLE_MODE); } - if(impl.console->goFullscreen) - { - goFullscreen(); - } - if(impl.console->crtMonitor) { impl.config->data.crtMonitor = true; @@ -1895,6 +1890,15 @@ Studio* studioInit(s32 argc, char **argv, s32 samplerate, const char* folder, Sy return &impl.studio; } +void studioInitPost() { + + if(impl.console->goFullscreen) + { + goFullscreen(); + } + +} + System* getSystem() { return impl.system; diff --git a/src/system.h b/src/system.h index ad718ba..81fc280 100644 --- a/src/system.h +++ b/src/system.h @@ -101,3 +101,4 @@ typedef struct } Studio; TIC80_API Studio* studioInit(s32 argc, char **argv, s32 samplerate, const char* appFolder, System* system); +TIC80_API void studioInitPost(); diff --git a/src/system/sdlgpu.c b/src/system/sdlgpu.c index 4420504..921c490 100644 --- a/src/system/sdlgpu.c +++ b/src/system/sdlgpu.c @@ -1455,6 +1455,8 @@ static s32 start(s32 argc, char **argv, const char* folder) SDL_GetWindowSize(platform.window, &w, &h); GPU_SetWindowResolution(w, h); } + + studioInitPost(); initTouchGamepad(); initTouchKeyboard();