diff options
-rw-r--r-- | apps/demo_menu.c | 81 | ||||
-rw-r--r-- | apps/demo_menu.h | 25 | ||||
-rw-r--r-- | apps/games_menu.c | 106 | ||||
-rw-r--r-- | apps/games_menu.h | 26 | ||||
-rw-r--r-- | apps/main_menu.c | 9 |
5 files changed, 0 insertions, 247 deletions
diff --git a/apps/demo_menu.c b/apps/demo_menu.c deleted file mode 100644 index be8e44522c..0000000000 --- a/apps/demo_menu.c +++ /dev/null | |||
@@ -1,81 +0,0 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2002 Robert Hak | ||
11 | * | ||
12 | * All files in this archive are subject to the GNU General Public License. | ||
13 | * See the file COPYING in the source tree root for full license agreement. | ||
14 | * | ||
15 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
16 | * KIND, either express or implied. | ||
17 | * | ||
18 | ****************************************************************************/ | ||
19 | #include "config.h" | ||
20 | #include "options.h" | ||
21 | |||
22 | #ifdef HAVE_LCD_BITMAP | ||
23 | #ifdef USE_DEMOS | ||
24 | |||
25 | #include <stdio.h> | ||
26 | #include <stdbool.h> | ||
27 | #include "menu.h" | ||
28 | #include "demo_menu.h" | ||
29 | #include "lang.h" | ||
30 | #include "plugin.h" | ||
31 | |||
32 | static bool bounce(void) | ||
33 | { | ||
34 | if (plugin_load("/.rockbox/rocks/bounce.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
35 | return true; | ||
36 | return false; | ||
37 | } | ||
38 | |||
39 | static bool snow(void) | ||
40 | { | ||
41 | if (plugin_load("/.rockbox/rocks/snow.rock",NULL) == PLUGIN_USB_CONNECTED) | ||
42 | return true; | ||
43 | return false; | ||
44 | } | ||
45 | |||
46 | static bool cube(void) | ||
47 | { | ||
48 | if (plugin_load("/.rockbox/rocks/cube.rock",NULL) == PLUGIN_USB_CONNECTED) | ||
49 | return true; | ||
50 | return false; | ||
51 | } | ||
52 | |||
53 | static bool oscillograph(void) | ||
54 | { | ||
55 | if (plugin_load("/.rockbox/rocks/oscillograph.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
56 | return true; | ||
57 | return false; | ||
58 | } | ||
59 | |||
60 | bool demo_menu(void) | ||
61 | { | ||
62 | int m; | ||
63 | bool result; | ||
64 | |||
65 | struct menu_items items[] = { | ||
66 | { str(LANG_BOUNCE), bounce }, | ||
67 | { str(LANG_SNOW), snow }, | ||
68 | { str(LANG_OSCILLOGRAPH), oscillograph }, | ||
69 | { str(LANG_CUBE), cube }, | ||
70 | }; | ||
71 | |||
72 | m=menu_init( items, sizeof items / sizeof(struct menu_items) ); | ||
73 | result = menu_run(m); | ||
74 | menu_exit(m); | ||
75 | |||
76 | return result; | ||
77 | } | ||
78 | |||
79 | #endif | ||
80 | #endif | ||
81 | |||
diff --git a/apps/demo_menu.h b/apps/demo_menu.h deleted file mode 100644 index dba057f4eb..0000000000 --- a/apps/demo_menu.h +++ /dev/null | |||
@@ -1,25 +0,0 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2002 Robert Hak | ||
11 | * | ||
12 | * All files in this archive are subject to the GNU General Public License. | ||
13 | * See the file COPYING in the source tree root for full license agreement. | ||
14 | * | ||
15 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
16 | * KIND, either express or implied. | ||
17 | * | ||
18 | ****************************************************************************/ | ||
19 | #ifndef _DEMOS_MENU_H | ||
20 | #define _DEMOS_MENU_H | ||
21 | |||
22 | bool demo_menu(void); | ||
23 | |||
24 | #endif | ||
25 | |||
diff --git a/apps/games_menu.c b/apps/games_menu.c deleted file mode 100644 index 16acd804ba..0000000000 --- a/apps/games_menu.c +++ /dev/null | |||
@@ -1,106 +0,0 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2002 Robert Hak | ||
11 | * | ||
12 | * All files in this archive are subject to the GNU General Public License. | ||
13 | * See the file COPYING in the source tree root for full license agreement. | ||
14 | * | ||
15 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
16 | * KIND, either express or implied. | ||
17 | * | ||
18 | ****************************************************************************/ | ||
19 | |||
20 | #include "config.h" | ||
21 | #include "options.h" | ||
22 | |||
23 | #ifdef HAVE_LCD_BITMAP | ||
24 | #ifdef USE_GAMES | ||
25 | |||
26 | #include <stdio.h> | ||
27 | #include <stdbool.h> | ||
28 | #include "menu.h" | ||
29 | #include "games_menu.h" | ||
30 | #include "lang.h" | ||
31 | #include "plugin.h" | ||
32 | |||
33 | static bool tetris(void) | ||
34 | { | ||
35 | if (plugin_load("/.rockbox/rocks/tetris.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
36 | return true; | ||
37 | return false; | ||
38 | } | ||
39 | |||
40 | static bool sokoban(void) | ||
41 | { | ||
42 | if (plugin_load("/.rockbox/rocks/sokoban.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
43 | return true; | ||
44 | return false; | ||
45 | } | ||
46 | |||
47 | static bool wormlet(void) | ||
48 | { | ||
49 | if (plugin_load("/.rockbox/rocks/wormlet.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
50 | return true; | ||
51 | return false; | ||
52 | } | ||
53 | |||
54 | static bool flipit(void) | ||
55 | { | ||
56 | if (plugin_load("/.rockbox/rocks/flipit.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
57 | return true; | ||
58 | return false; | ||
59 | } | ||
60 | |||
61 | static bool othelo(void) | ||
62 | { | ||
63 | if (plugin_load("/.rockbox/rocks/othelo.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
64 | return true; | ||
65 | return false; | ||
66 | } | ||
67 | |||
68 | static bool sliding_puzzle(void) | ||
69 | { | ||
70 | if (plugin_load("/.rockbox/rocks/sliding_puzzle.rock", | ||
71 | NULL)==PLUGIN_USB_CONNECTED) | ||
72 | return true; | ||
73 | return false; | ||
74 | } | ||
75 | |||
76 | static bool star(void) | ||
77 | { | ||
78 | if (plugin_load("/.rockbox/rocks/star.rock",NULL)==PLUGIN_USB_CONNECTED) | ||
79 | return true; | ||
80 | return false; | ||
81 | } | ||
82 | |||
83 | bool games_menu(void) | ||
84 | { | ||
85 | int m; | ||
86 | bool result; | ||
87 | |||
88 | struct menu_items items[] = { | ||
89 | { str(LANG_TETRIS), tetris }, | ||
90 | { str(LANG_SOKOBAN), sokoban }, | ||
91 | { str(LANG_WORMLET), wormlet }, | ||
92 | { str(LANG_FLIPIT), flipit }, | ||
93 | { str(LANG_OTHELO), othelo }, | ||
94 | { str(LANG_SLIDING_PUZZLE), sliding_puzzle }, | ||
95 | { str(LANG_STAR), star }, | ||
96 | }; | ||
97 | |||
98 | m=menu_init( items, sizeof items / sizeof(struct menu_items) ); | ||
99 | result = menu_run(m); | ||
100 | menu_exit(m); | ||
101 | |||
102 | return result; | ||
103 | } | ||
104 | |||
105 | #endif | ||
106 | #endif | ||
diff --git a/apps/games_menu.h b/apps/games_menu.h deleted file mode 100644 index 5c6d81b5a5..0000000000 --- a/apps/games_menu.h +++ /dev/null | |||
@@ -1,26 +0,0 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2002 Robert Hak | ||
11 | * | ||
12 | * All files in this archive are subject to the GNU General Public License. | ||
13 | * See the file COPYING in the source tree root for full license agreement. | ||
14 | * | ||
15 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
16 | * KIND, either express or implied. | ||
17 | * | ||
18 | ****************************************************************************/ | ||
19 | #ifndef _GAMES_MENU_H | ||
20 | #define _GAMES_MENU_H | ||
21 | |||
22 | #include "menu.h" | ||
23 | |||
24 | bool games_menu(void); | ||
25 | |||
26 | #endif | ||
diff --git a/apps/main_menu.c b/apps/main_menu.c index eb68eb64b6..01aa3dc30c 100644 --- a/apps/main_menu.c +++ b/apps/main_menu.c | |||
@@ -61,15 +61,6 @@ | |||
61 | #ifdef HAVE_LCD_BITMAP | 61 | #ifdef HAVE_LCD_BITMAP |
62 | #include "bmp.h" | 62 | #include "bmp.h" |
63 | #include "icons.h" | 63 | #include "icons.h" |
64 | |||
65 | #ifdef USE_GAMES | ||
66 | #include "games_menu.h" | ||
67 | #endif /* End USE_GAMES */ | ||
68 | |||
69 | #ifdef USE_DEMOS | ||
70 | #include "demo_menu.h" | ||
71 | #endif /* End USE_DEMOS */ | ||
72 | |||
73 | #endif /* End HAVE_LCD_BITMAP */ | 64 | #endif /* End HAVE_LCD_BITMAP */ |
74 | 65 | ||
75 | int show_logo( void ) | 66 | int show_logo( void ) |