From 5366ec606d9e21820743a0e1747de8d7ad0e9a39 Mon Sep 17 00:00:00 2001 From: "BADIM-PC\\Vadim" Date: Wed, 14 Feb 2018 15:23:26 +0300 Subject: [PATCH] no message --- src/studio.c | 1 + src/studio.h | 2 +- src/system.c | 2 +- src/system.h | 1 + 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/studio.c b/src/studio.c index 27fbe71..6bc80ff 100644 --- a/src/studio.c +++ b/src/studio.c @@ -1874,6 +1874,7 @@ Studio* studioInit(s32 argc, char **argv, s32 samplerate, const char* folder, Sy studioImpl.studio.tick = studioTick; studioImpl.studio.close = studioClose; studioImpl.studio.updateProject = updateStudioProject; + studioImpl.studio.exit = exitStudio; return &studioImpl.studio; } diff --git a/src/studio.h b/src/studio.h index f38c12f..d1a0ef9 100644 --- a/src/studio.h +++ b/src/studio.h @@ -154,7 +154,7 @@ void studioConfigChanged(); void setStudioMode(EditorMode mode); void resumeRunMode(); EditorMode getStudioMode(); -TIC80_API void exitStudio(); +void exitStudio(); u32 unzip(u8** dest, const u8* source, size_t size); void str2buf(const char* str, s32 size, void* buf, bool flip); diff --git a/src/system.c b/src/system.c index b1eec29..540ec81 100644 --- a/src/system.c +++ b/src/system.c @@ -584,7 +584,7 @@ static void pollEvent() } break; case SDL_QUIT: - exitStudio(); + platform.studio->exit(); break; default: break; diff --git a/src/system.h b/src/system.h index 2036e6d..b7b333b 100644 --- a/src/system.h +++ b/src/system.h @@ -30,6 +30,7 @@ typedef struct bool quit; void (*tick)(void* pixels); + void (*exit)(); void (*close)(); void (*updateProject)();