diff options
author | Michael Sevakis <jethead71@rockbox.org> | 2010-06-19 20:36:54 +0000 |
---|---|---|
committer | Michael Sevakis <jethead71@rockbox.org> | 2010-06-19 20:36:54 +0000 |
commit | 910101d613c57450ee02b68c2eba531a8c4bcdda (patch) | |
tree | 0acf3da0e9838b5dd3d3084cbbc0e2b8ab59361e /firmware | |
parent | 4932362e11425550d619e6c2de9f896879b7837f (diff) |
iPod 3G: Add a small check to ensure backlight never gets stuck off if wheel is inactive for too long (because it limits the number of backlight_on calls).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26964 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/target/arm/ipod/button-1g-3g.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/firmware/target/arm/ipod/button-1g-3g.c b/firmware/target/arm/ipod/button-1g-3g.c index 044e887453..9eec8fd823 100644 --- a/firmware/target/arm/ipod/button-1g-3g.c +++ b/firmware/target/arm/ipod/button-1g-3g.c @@ -151,6 +151,9 @@ static void handle_scroll_wheel(int new_scroll, int was_hold) if (v < WHEEL_SMOOTHING_VELOCITY) { /* very slow - no smoothing */ wheel_velocity = v; + /* ensure backlight never gets stuck for an extended period if tick + * wrapped such that next poke is very far ahead */ + next_backlight_on = current_tick - 1; } else { /* some velocity filtering to smooth things out */ |