Fix FS#12351: The poweroff timer was not reset on scroll wheel activity for e200 and simulator. Thanks to Nick Peskett.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30847 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
e126153687
commit
b8223d908b
2 changed files with 4 additions and 0 deletions
|
@ -23,6 +23,7 @@
|
||||||
#include "button.h"
|
#include "button.h"
|
||||||
#include "kernel.h"
|
#include "kernel.h"
|
||||||
#include "backlight.h"
|
#include "backlight.h"
|
||||||
|
#include "powermgmt.h"
|
||||||
|
|
||||||
void scrollwheel(unsigned int wheel_value)
|
void scrollwheel(unsigned int wheel_value)
|
||||||
{
|
{
|
||||||
|
@ -108,6 +109,7 @@ void scrollwheel(unsigned int wheel_value)
|
||||||
{
|
{
|
||||||
buttonlight_on();
|
buttonlight_on();
|
||||||
backlight_on();
|
backlight_on();
|
||||||
|
reset_poweroff_timer();
|
||||||
queue_post(&button_queue, btn, ((wheel_delta+1)<<24));
|
queue_post(&button_queue, btn, ((wheel_delta+1)<<24));
|
||||||
/* message posted - reset count and remember post */
|
/* message posted - reset count and remember post */
|
||||||
counter = 0;
|
counter = 0;
|
||||||
|
|
|
@ -33,6 +33,7 @@
|
||||||
#include "sim_tasks.h"
|
#include "sim_tasks.h"
|
||||||
#include "buttonmap.h"
|
#include "buttonmap.h"
|
||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
|
#include "powermgmt.h"
|
||||||
|
|
||||||
#ifdef HAVE_TOUCHSCREEN
|
#ifdef HAVE_TOUCHSCREEN
|
||||||
#include "touchscreen.h"
|
#include "touchscreen.h"
|
||||||
|
@ -418,6 +419,7 @@ static void button_event(int key, bool pressed)
|
||||||
#ifdef HAVE_BUTTON_LIGHT
|
#ifdef HAVE_BUTTON_LIGHT
|
||||||
buttonlight_on();
|
buttonlight_on();
|
||||||
#endif
|
#endif
|
||||||
|
reset_poweroff_timer();
|
||||||
queue_post(&button_queue, new_btn, 1<<24);
|
queue_post(&button_queue, new_btn, 1<<24);
|
||||||
new_btn &= ~(BUTTON_SCROLL_FWD | BUTTON_SCROLL_BACK);
|
new_btn &= ~(BUTTON_SCROLL_FWD | BUTTON_SCROLL_BACK);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue