summaryrefslogtreecommitdiff
path: root/apps/main_menu.c
diff options
context:
space:
mode:
authorLinus Nielsen Feltzing <linus@haxx.se>2005-07-05 00:03:18 +0000
committerLinus Nielsen Feltzing <linus@haxx.se>2005-07-05 00:03:18 +0000
commit6e80ac39a5a3e7091c14db19cac791c9ddb8849f (patch)
treee719274318b79d5fc5e5df8a01ad1b32a9be7745 /apps/main_menu.c
parent839dbcaed7ea135dcc0812de76f9ff5c1dc924f5 (diff)
downloadrockbox-6e80ac39a5a3e7091c14db19cac791c9ddb8849f.zip
rockbox-6e80ac39a5a3e7091c14db19cac791c9ddb8849f.tar.gz
rockbox-6e80ac39a5a3e7091c14db19cac791c9ddb8849f.tar.bz2
rockbox-6e80ac39a5a3e7091c14db19cac791c9ddb8849f.tar.xz
New poweroff handling, using the SYS_POWEROFF event, allowing plugins to save their settings before powering off.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7019 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/main_menu.c')
-rw-r--r--apps/main_menu.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/apps/main_menu.c b/apps/main_menu.c
index 68d6699..87518cf 100644
--- a/apps/main_menu.c
+++ b/apps/main_menu.c
@@ -361,6 +361,13 @@ bool info_menu(void)
return result;
}
+#ifdef HAVE_LCD_CHARCELLS
+static void do_shutdown(void)
+{
+ sys_poweroff(false);
+}
+#endif
+
bool main_menu(void)
{
int m;
@@ -405,7 +412,7 @@ bool main_menu(void)
#ifdef HAVE_LCD_CHARCELLS
items[i].desc = ID2P(LANG_SHUTDOWN);
- items[i++].function = clean_shutdown;
+ items[i++].function = do_shutdown;
#endif
m=menu_init( items, i, NULL, NULL, NULL, NULL );