Mercurial > MadButterfly
comparison examples/menu/animated_menu.h @ 323:33e8ff8b7ad2
Check in missing file
author | wycc |
---|---|
date | Thu, 05 Mar 2009 14:31:38 +0800 |
parents | |
children | f90c60967a9c |
comparison
equal
deleted
inserted
replaced
321:44cc65e7e234 | 323:33e8ff8b7ad2 |
---|---|
1 #ifndef __ANIMATED_MENU_H | |
2 #define __ANIMATED_MENU_H | |
3 typedef struct _mb_animated_menu { | |
4 char **titles; | |
5 int *menus_y; | |
6 int *items; | |
7 int top; | |
8 int cur; | |
9 int max; | |
10 int ready; | |
11 int speed; | |
12 MBApp *app; | |
13 mb_sprite_t *sprite; | |
14 mb_obj_t **objects; | |
15 mb_obj_t *lightbar; | |
16 void (*callback)(struct _mb_animated_menu *m, int sel); | |
17 } mb_animated_menu_t; | |
18 /** \brief Create an instace of animated menu. | |
19 * | |
20 * The objectnames is used to extract symbols from the SVG file. | |
21 * ${objectnames}0 - ${objectnames}8 is the text object. | |
22 * ${objectnames}_lightbar is the lightbar. | |
23 * | |
24 */ | |
25 mb_animated_menu_t *mb_animated_menu_new(MBApp *app,mb_sprite_t *sp,char *objnames,char *menus[]); | |
26 void mb_animated_menu_set_speed(mb_animated_menu_t *m,int speed); | |
27 int mb_animated_menu_get_speed(mb_animated_menu_t *m); | |
28 void mb_animated_menu_set_callback(mb_animated_menu_t *m, void (*f)(mb_animated_menu_t *m, int sel)); | |
29 #endif |