forked from len0rd/rockbox
fixed the check for the release events
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@2749 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
b351656491
commit
061763b2a6
1 changed files with 4 additions and 8 deletions
|
|
@ -243,15 +243,13 @@ static int scrollit(void)
|
||||||
char rock[]="Rockbox! Pure pleasure. Pure fun. Oooh. What fun! ;-) ";
|
char rock[]="Rockbox! Pure pleasure. Pure fun. Oooh. What fun! ;-) ";
|
||||||
int letter;
|
int letter;
|
||||||
|
|
||||||
while(button_get(false) & BUTTON_REL);
|
|
||||||
|
|
||||||
lcd_clear_display();
|
lcd_clear_display();
|
||||||
while(1)
|
while(1)
|
||||||
{
|
{
|
||||||
b = button_get_w_tmo(HZ/10);
|
b = button_get_w_tmo(HZ/10);
|
||||||
if ( b & BUTTON_OFF )
|
if ( b == (BUTTON_OFF|BUTTON_REL) )
|
||||||
return 0;
|
return 0;
|
||||||
else if ( b & BUTTON_ON )
|
else if ( b == (BUTTON_ON|BUTTON_REL) )
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
lcd_clear_display();
|
lcd_clear_display();
|
||||||
|
|
@ -297,15 +295,13 @@ static int loopit(void)
|
||||||
int timeout=0;
|
int timeout=0;
|
||||||
char buffer[30];
|
char buffer[30];
|
||||||
|
|
||||||
while(button_get(false) & BUTTON_REL);
|
|
||||||
|
|
||||||
lcd_clear_display();
|
lcd_clear_display();
|
||||||
while(1)
|
while(1)
|
||||||
{
|
{
|
||||||
b = button_get_w_tmo(HZ/10);
|
b = button_get_w_tmo(HZ/10);
|
||||||
if ( b & BUTTON_OFF )
|
if ( b == (BUTTON_OFF|BUTTON_REL) )
|
||||||
return 0;
|
return 0;
|
||||||
if ( b & BUTTON_ON )
|
if ( b == (BUTTON_ON|BUTTON_REL) )
|
||||||
return 1;
|
return 1;
|
||||||
else if(b != BUTTON_NONE)
|
else if(b != BUTTON_NONE)
|
||||||
timeout=20;
|
timeout=20;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue