diff options
Diffstat (limited to 'apps/games_menu.c')
-rw-r--r-- | apps/games_menu.c | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/apps/games_menu.c b/apps/games_menu.c new file mode 100644 index 0000000000..caee2b464c --- /dev/null +++ b/apps/games_menu.c | |||
@@ -0,0 +1,52 @@ | |||
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 | #ifdef HAVE_LCD_BITMAP | ||
20 | |||
21 | #include "config.h" | ||
22 | #include <stdio.h> | ||
23 | #include <stdbool.h> | ||
24 | #include "lcd.h" | ||
25 | #include "menu.h" | ||
26 | #include "games_menu.h" | ||
27 | #include "button.h" | ||
28 | #include "kernel.h" | ||
29 | #include "sprintf.h" | ||
30 | |||
31 | #include "sokoban.h" | ||
32 | extern void tetris(void); | ||
33 | |||
34 | enum { Tetris, Sokoban, numgames }; | ||
35 | |||
36 | void games_menu(void) | ||
37 | { | ||
38 | int m; | ||
39 | |||
40 | struct menu_items items[] = { | ||
41 | { Tetris, "Tetris", tetris }, | ||
42 | { Sokoban, "Sokoban", sokoban }, | ||
43 | }; | ||
44 | |||
45 | m=menu_init( items, sizeof items / sizeof(struct menu_items) ); | ||
46 | menu_run(m); | ||
47 | menu_exit(m); | ||
48 | } | ||
49 | |||
50 | #endif | ||
51 | |||
52 | |||