forked from len0rd/rockbox
credits and version merged
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@844 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
a895626516
commit
65379df445
3 changed files with 17 additions and 12 deletions
|
|
@ -58,13 +58,14 @@ struct credit credits[] = {
|
||||||
#define DISPLAY_TIME HZ
|
#define DISPLAY_TIME HZ
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void show_credits(void)
|
void roll_credits(void)
|
||||||
{
|
{
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
int j;
|
int j;
|
||||||
int line = 0;
|
int line = 0;
|
||||||
|
|
||||||
lcd_clear_display();
|
lcd_clear_display();
|
||||||
|
|
||||||
#ifdef HAVE_LCD_BITMAP
|
#ifdef HAVE_LCD_BITMAP
|
||||||
lcd_setmargins(0,9);
|
lcd_setmargins(0,9);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@
|
||||||
#define __ROCKBOX_CREDITS_H__
|
#define __ROCKBOX_CREDITS_H__
|
||||||
|
|
||||||
/* Show who worked on the project */
|
/* Show who worked on the project */
|
||||||
void show_credits(void);
|
void roll_credits(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -82,19 +82,27 @@ int show_logo( void )
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void show_splash(void)
|
void show_credits(void)
|
||||||
{
|
{
|
||||||
if (show_logo() != 0)
|
int j = 0;
|
||||||
return;
|
|
||||||
|
|
||||||
button_get(true);
|
show_logo();
|
||||||
|
|
||||||
|
for (j = 0; j < 10; j++) {
|
||||||
|
sleep((HZ*2)/10);
|
||||||
|
|
||||||
|
if (button_get(false))
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
roll_credits();
|
||||||
}
|
}
|
||||||
|
|
||||||
void main_menu(void)
|
void main_menu(void)
|
||||||
{
|
{
|
||||||
int m;
|
int m;
|
||||||
enum {
|
enum {
|
||||||
Tetris, Screen_Saver, Splash, Credits, Sound
|
Tetris, Screen_Saver, Version, Sound
|
||||||
};
|
};
|
||||||
|
|
||||||
/* main menu */
|
/* main menu */
|
||||||
|
|
@ -104,14 +112,10 @@ void main_menu(void)
|
||||||
{ Tetris, "Tetris", tetris },
|
{ Tetris, "Tetris", tetris },
|
||||||
{ Screen_Saver, "Screen Saver", screensaver },
|
{ Screen_Saver, "Screen Saver", screensaver },
|
||||||
#endif
|
#endif
|
||||||
{ Splash, "Splash", show_splash },
|
{ Version, "Version", show_credits },
|
||||||
{ Credits, "Credits", show_credits },
|
|
||||||
};
|
};
|
||||||
|
|
||||||
m=menu_init( items, sizeof items / sizeof(struct menu_items) );
|
m=menu_init( items, sizeof items / sizeof(struct menu_items) );
|
||||||
menu_run(m);
|
menu_run(m);
|
||||||
menu_exit(m);
|
menu_exit(m);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue