(Win32) Works now with Win32 Mingw - had to implement mmap implementation
[picodrive.git] / platform / common / plat_sdl.c
index 28b412d..600af45 100644 (file)
 #include "input_pico.h"
 #include "version.h"
 
-// FIXME: these 2 shouldn't be here
-static unsigned char PicoDraw2FB_[(8+320) * (8+240+8)];
-unsigned char *PicoDraw2FB = PicoDraw2FB_;
-
 static void *shadow_fb;
 
 static const struct in_default_bind in_sdl_defbinds[] = {
@@ -142,6 +138,7 @@ void plat_video_wait_vsync(void)
 void plat_video_menu_enter(int is_rom_loaded)
 {
        plat_sdl_change_video_mode(g_menuscreen_w, g_menuscreen_h, 0);
+       g_screen_ptr = shadow_fb;
 }
 
 void plat_video_menu_begin(void)
@@ -200,6 +197,12 @@ void plat_early_init(void)
 {
 }
 
+static void plat_sdl_quit(void)
+{
+       // for now..
+       exit(1);
+}
+
 void plat_init(void)
 {
        int shadow_size;
@@ -209,7 +212,9 @@ void plat_init(void)
        if (ret != 0)
                exit(1);
 
-       SDL_WM_SetCaption("PicoDrive" VERSION, NULL);
+       plat_sdl_quit_cb = plat_sdl_quit;
+
+       SDL_WM_SetCaption("PicoDrive " VERSION, NULL);
 
        g_menuscreen_w = plat_sdl_screen->w;
        g_menuscreen_h = plat_sdl_screen->h;