summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorMarc Guay <marcguay@rockbox.org>2009-05-22 13:51:56 +0000
committerMarc Guay <marcguay@rockbox.org>2009-05-22 13:51:56 +0000
commit814b3dbfbc095fcedab3737c45f93283f84cb1ea (patch)
tree7711ee08d6c99126d2ecc13c573cb291e2146442 /apps
parent8872b60fb92da185ad3e387730fa1b57c6fbe11a (diff)
downloadrockbox-814b3dbfbc095fcedab3737c45f93283f84cb1ea.tar.gz
rockbox-814b3dbfbc095fcedab3737c45f93283f84cb1ea.zip
FS#10230 - Remove 'start new file if not recording' functionality from ACTION_REC_NEWFILE
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21034 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r--apps/recorder/recording.c40
1 files changed, 21 insertions, 19 deletions
diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c
index 5b5dc55b40..f627399738 100644
--- a/apps/recorder/recording.c
+++ b/apps/recorder/recording.c
@@ -1518,8 +1518,18 @@ bool recording_screen(bool no_source)
update_countdown = 0; /* Update immediately */
break;
#endif
- case ACTION_REC_PAUSE:
case ACTION_REC_NEWFILE:
+
+ /* Only act if in the middle of recording. */
+ if(audio_stat & AUDIO_STATUS_RECORD)
+ {
+ rec_command(RECORDING_CMD_START_NEWFILE);
+ last_seconds = 0;
+ }
+ break;
+
+ case ACTION_REC_PAUSE:
+
/* Only act if the mpeg is stopped */
if(!(audio_stat & AUDIO_STATUS_RECORD))
{
@@ -1547,30 +1557,22 @@ bool recording_screen(bool no_source)
peak_meter_set_trigger_listener(&trigger_listener);
}
}
+ /* If we're in the middle of recording */
else
{
- /*if new file button pressed, start new file */
- if (button == ACTION_REC_NEWFILE)
+ /* if pause button pressed, pause or resume */
+ if(audio_stat & AUDIO_STATUS_PAUSE)
{
- rec_command(RECORDING_CMD_START_NEWFILE);
- last_seconds = 0;
+ rec_command(RECORDING_CMD_RESUME);
+ if (global_settings.talk_menu)
+ {
+ /* no voice possible here, but a beep */
+ audio_beep(HZ/4); /* short beep on resume */
+ }
}
else
- /* if pause button pressed, pause or resume */
{
- if(audio_stat & AUDIO_STATUS_PAUSE)
- {
- rec_command(RECORDING_CMD_RESUME);
- if (global_settings.talk_menu)
- {
- /* no voice possible here, but a beep */
- audio_beep(HZ/4); /* short beep on resume */
- }
- }
- else
- {
- rec_command(RECORDING_CMD_PAUSE);
- }
+ rec_command(RECORDING_CMD_PAUSE);
}
}
update_countdown = 0; /* Update immediately */