diff options
author | Björn Stenberg <bjorn@haxx.se> | 2003-11-25 12:00:25 +0000 |
---|---|---|
committer | Björn Stenberg <bjorn@haxx.se> | 2003-11-25 12:00:25 +0000 |
commit | 53989844b4ea998fb83173692d00e73f21dd66a3 (patch) | |
tree | 9b48b0bceffaadf5df8c57f4fad9d93fc29fe59b /firmware/powermgmt.c | |
parent | 152f07e4785a29f912152f9fc0a5b461c9d79cc7 (diff) | |
download | rockbox-53989844b4ea998fb83173692d00e73f21dd66a3.tar.gz rockbox-53989844b4ea998fb83173692d00e73f21dd66a3.zip |
Bug fix: Idle timeout would stop paused playback when charger was connected
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4066 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/powermgmt.c')
-rw-r--r-- | firmware/powermgmt.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/firmware/powermgmt.c b/firmware/powermgmt.c index 80b6a80b2b..374f10c8f8 100644 --- a/firmware/powermgmt.c +++ b/firmware/powermgmt.c | |||
@@ -315,17 +315,10 @@ static void handle_auto_poweroff(void) | |||
315 | !sleeptimer_active))) | 315 | !sleeptimer_active))) |
316 | { | 316 | { |
317 | if(TIME_AFTER(current_tick, last_keypress + timeout) && | 317 | if(TIME_AFTER(current_tick, last_keypress + timeout) && |
318 | TIME_AFTER(current_tick, last_disk_activity + timeout)) | 318 | TIME_AFTER(current_tick, last_disk_activity + timeout) && |
319 | TIME_AFTER(current_tick, last_charge_time + timeout)) | ||
319 | { | 320 | { |
320 | if (mpeg_stat == (MPEG_STATUS_PLAY | MPEG_STATUS_PAUSE)) | 321 | power_off(); |
321 | { | ||
322 | mpeg_stop(); | ||
323 | } | ||
324 | |||
325 | if (TIME_AFTER(current_tick, last_charge_time + timeout)) | ||
326 | { | ||
327 | power_off(); | ||
328 | } | ||
329 | } | 322 | } |
330 | } | 323 | } |
331 | else | 324 | else |