From d8f6c75ab94ee97e9a49ce669d74dc252225586a Mon Sep 17 00:00:00 2001 From: Thomas Martitz Date: Mon, 28 Feb 2011 03:24:48 +0000 Subject: Hopefully get shutdown/exit handling on SDL/maemo right. Make shutdown_hw() not return as it's supposed to, ensure sim_do_exit() is called from main thread and move sim_kernel_shutdown() into it to simplify things. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29455 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/hosted/sdl/button-sdl.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'firmware/target/hosted/sdl/button-sdl.c') diff --git a/firmware/target/hosted/sdl/button-sdl.c b/firmware/target/hosted/sdl/button-sdl.c index 00afc0c8ef..f14e53fb44 100644 --- a/firmware/target/hosted/sdl/button-sdl.c +++ b/firmware/target/hosted/sdl/button-sdl.c @@ -275,8 +275,8 @@ static bool event_handler(SDL_Event *event) break; } case SDL_QUIT: - /* Post SYS_POWEROFF event. Will post SDL_USEREVENT in shutdown_hw() if successful. */ - queue_broadcast(SYS_POWEROFF, 0); + /* Will post SDL_USEREVENT in shutdown_hw() if successful. */ + sys_poweroff(); break; case SDL_USEREVENT: return true; @@ -324,8 +324,8 @@ static void button_event(int key, bool pressed) #if (CONFIG_PLATFORM & PLATFORM_PANDORA) case SDLK_LCTRL: - /* Post SYS_POWEROFF event. Will post SDL_USEREVENT in shutdown_hw() if successful. */ - queue_broadcast(SYS_POWEROFF, 0); + /* Will post SDL_USEREVENT in shutdown_hw() if successful. */ + sys_poweroff(); break; #endif #ifdef HAS_BUTTON_HOLD -- cgit v1.2.3