1
0
Fork 0
forked from len0rd/rockbox

Make test_mem.c and test_boost.c compilable on targets without BUTTON_UP.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25464 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Andree Buschmann 2010-04-03 23:14:25 +00:00
parent f8811835e0
commit dc19fb37d5
2 changed files with 10 additions and 8 deletions

View file

@ -55,7 +55,8 @@ enum plugin_status plugin_start(const void* parameter)
int button = rb->button_get(false); int button = rb->button_get(false);
switch (button) switch (button)
{ {
case BUTTON_UP: #ifdef HAVE_ADJUSTABLE_CPU_FREQ
case ACTION_STD_PREV:
if (!boost) if (!boost)
{ {
rb->cpu_boost(true); rb->cpu_boost(true);
@ -63,15 +64,15 @@ enum plugin_status plugin_start(const void* parameter)
} }
break; break;
case BUTTON_DOWN: case ACTION_STD_NEXT:
if (boost) if (boost)
{ {
rb->cpu_boost(false); rb->cpu_boost(false);
boost = false; boost = false;
} }
break; break;
#endif
case BUTTON_LEFT: case ACTION_STD_CANCEL:
done = true; done = true;
break; break;
} }

View file

@ -72,7 +72,8 @@ enum plugin_status plugin_start(const void* parameter)
int button = rb->button_get(false); int button = rb->button_get(false);
switch (button) switch (button)
{ {
case BUTTON_UP: #ifdef HAVE_ADJUSTABLE_CPU_FREQ
case ACTION_STD_PREV:
if (!boost) if (!boost)
{ {
rb->cpu_boost(true); rb->cpu_boost(true);
@ -80,15 +81,15 @@ enum plugin_status plugin_start(const void* parameter)
} }
break; break;
case BUTTON_DOWN: case ACTION_STD_NEXT:
if (boost) if (boost)
{ {
rb->cpu_boost(false); rb->cpu_boost(false);
boost = false; boost = false;
} }
break; break;
#endif
case BUTTON_LEFT: case ACTION_STD_CANCEL:
done = true; done = true;
break; break;
} }