diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/lang/english.lang | 18 | ||||
-rw-r--r-- | apps/lang/nederlands.lang | 18 | ||||
-rw-r--r-- | apps/lang/polski.lang | 18 | ||||
-rw-r--r-- | apps/recorder/recording.c | 16 | ||||
-rw-r--r-- | apps/recorder/recording.h | 3 | ||||
-rw-r--r-- | apps/settings_list.c | 4 |
6 files changed, 73 insertions, 4 deletions
diff --git a/apps/lang/english.lang b/apps/lang/english.lang index 3c2fae174d..2a087bb5cf 100644 --- a/apps/lang/english.lang +++ b/apps/lang/english.lang | |||
@@ -11696,3 +11696,21 @@ | |||
11696 | *: "OK" | 11696 | *: "OK" |
11697 | </voice> | 11697 | </voice> |
11698 | </phrase> | 11698 | </phrase> |
11699 | <phrase> | ||
11700 | id: LANG_STOP_RECORDING_AND_SHUTDOWN | ||
11701 | desc: in record timesplit options | ||
11702 | user: | ||
11703 | <source> | ||
11704 | *: none | ||
11705 | recording: "Stop Recording And Shutdown" | ||
11706 | </source> | ||
11707 | <dest> | ||
11708 | *: none | ||
11709 | recording: "Stop Recording And Shutdown" | ||
11710 | </dest> | ||
11711 | <voice> | ||
11712 | *: none | ||
11713 | recording: "Stop Recording And Shutdown" | ||
11714 | </voice> | ||
11715 | </phrase> | ||
11716 | <phrase> | ||
diff --git a/apps/lang/nederlands.lang b/apps/lang/nederlands.lang index 9c2d94f595..4193ca8c25 100644 --- a/apps/lang/nederlands.lang +++ b/apps/lang/nederlands.lang | |||
@@ -11653,3 +11653,21 @@ | |||
11653 | *: "OK" | 11653 | *: "OK" |
11654 | </voice> | 11654 | </voice> |
11655 | </phrase> | 11655 | </phrase> |
11656 | <phrase> | ||
11657 | id: LANG_STOP_RECORDING_AND_SHUTDOWN | ||
11658 | desc: in record timesplit options | ||
11659 | user: | ||
11660 | <source> | ||
11661 | *: none | ||
11662 | recording: "Stop Recording And Shutdown" | ||
11663 | </source> | ||
11664 | <dest> | ||
11665 | *: none | ||
11666 | recording: "Stop opname en zet uit" | ||
11667 | </dest> | ||
11668 | <voice> | ||
11669 | *: none | ||
11670 | recording: "Stop opname en zet uit" | ||
11671 | </voice> | ||
11672 | </phrase> | ||
11673 | <phrase> | ||
diff --git a/apps/lang/polski.lang b/apps/lang/polski.lang index 15f51a7409..cca01eadd5 100644 --- a/apps/lang/polski.lang +++ b/apps/lang/polski.lang | |||
@@ -11556,3 +11556,21 @@ | |||
11556 | swcodec: "Powtarzaj dźwięk klawiszy" | 11556 | swcodec: "Powtarzaj dźwięk klawiszy" |
11557 | </voice> | 11557 | </voice> |
11558 | </phrase> | 11558 | </phrase> |
11559 | <phrase> | ||
11560 | id: LANG_STOP_RECORDING_AND_SHUTDOWN | ||
11561 | desc: in record timesplit options | ||
11562 | user: | ||
11563 | <source> | ||
11564 | *: none | ||
11565 | recording: "Stop Recording And Shutdown" | ||
11566 | </source> | ||
11567 | <dest> | ||
11568 | *: none | ||
11569 | recording: "Zatrzymaj nagrywanie i wyłącz" | ||
11570 | </dest> | ||
11571 | <voice> | ||
11572 | *: none | ||
11573 | recording: "Zatrzymaj nagrywanie i wyłącz" | ||
11574 | </voice> | ||
11575 | </phrase> | ||
11576 | <phrase> | ||
diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c index 6a2b9257d4..715a06d823 100644 --- a/apps/recorder/recording.c +++ b/apps/recorder/recording.c | |||
@@ -25,6 +25,7 @@ | |||
25 | 25 | ||
26 | #include "system.h" | 26 | #include "system.h" |
27 | #include "power.h" | 27 | #include "power.h" |
28 | #include "powermgmt.h" | ||
28 | #include "lcd.h" | 29 | #include "lcd.h" |
29 | #include "led.h" | 30 | #include "led.h" |
30 | #include "mpeg.h" | 31 | #include "mpeg.h" |
@@ -717,6 +718,12 @@ void rec_command(enum recording_command cmd) | |||
717 | { | 718 | { |
718 | switch(cmd) | 719 | switch(cmd) |
719 | { | 720 | { |
721 | case RECORDING_CMD_STOP_SHUTDOWN: | ||
722 | pm_activate_clipcount(false); | ||
723 | audio_stop_recording(); | ||
724 | audio_close_recording(); | ||
725 | sys_poweroff(); | ||
726 | break; | ||
720 | case RECORDING_CMD_STOP: | 727 | case RECORDING_CMD_STOP: |
721 | pm_activate_clipcount(false); | 728 | pm_activate_clipcount(false); |
722 | audio_stop_recording(); | 729 | audio_stop_recording(); |
@@ -808,6 +815,10 @@ static void trigger_listener(int trigger_status) | |||
808 | /* tell recording_screen to reset the time */ | 815 | /* tell recording_screen to reset the time */ |
809 | last_seconds = 0; | 816 | last_seconds = 0; |
810 | break; | 817 | break; |
818 | |||
819 | case 3: /* Stop and shutdown */ | ||
820 | rec_command(RECORDING_CMD_STOP_SHUTDOWN); | ||
821 | break; | ||
811 | } | 822 | } |
812 | 823 | ||
813 | if (global_settings.rec_trigger_mode != TRIG_MODE_REARM) | 824 | if (global_settings.rec_trigger_mode != TRIG_MODE_REARM) |
@@ -1571,7 +1582,10 @@ bool recording_screen(bool no_source) | |||
1571 | { | 1582 | { |
1572 | peak_meter_trigger(false); | 1583 | peak_meter_trigger(false); |
1573 | peak_meter_set_trigger_listener(NULL); | 1584 | peak_meter_set_trigger_listener(NULL); |
1574 | rec_command(RECORDING_CMD_STOP); | 1585 | if( global_settings.rec_split_type == 1) |
1586 | rec_command(RECORDING_CMD_STOP); | ||
1587 | else | ||
1588 | rec_command(RECORDING_CMD_STOP_SHUTDOWN); | ||
1575 | } | 1589 | } |
1576 | update_countdown = 1; | 1590 | update_countdown = 1; |
1577 | } | 1591 | } |
diff --git a/apps/recorder/recording.h b/apps/recorder/recording.h index a622f01d40..11d6e86e8c 100644 --- a/apps/recorder/recording.h +++ b/apps/recorder/recording.h | |||
@@ -49,7 +49,8 @@ enum recording_command | |||
49 | start recording */ | 49 | start recording */ |
50 | RECORDING_CMD_START_NEWFILE, /* create unique filename and start recording*/ | 50 | RECORDING_CMD_START_NEWFILE, /* create unique filename and start recording*/ |
51 | RECORDING_CMD_PAUSE, | 51 | RECORDING_CMD_PAUSE, |
52 | RECORDING_CMD_RESUME | 52 | RECORDING_CMD_RESUME, |
53 | RECORDING_CMD_STOP_SHUTDOWN /* stop recording and shutdown */ | ||
53 | }; | 54 | }; |
54 | 55 | ||
55 | /* centralized way to start/stop/... recording */ | 56 | /* centralized way to start/stop/... recording */ |
diff --git a/apps/settings_list.c b/apps/settings_list.c index a08639996c..17ca714e76 100644 --- a/apps/settings_list.c +++ b/apps/settings_list.c | |||
@@ -844,8 +844,8 @@ const struct settings_list settings[] = { | |||
844 | {F_T_INT|F_RECSETTING, &global_settings.rec_channels, LANG_CHANNELS, INT(0), | 844 | {F_T_INT|F_RECSETTING, &global_settings.rec_channels, LANG_CHANNELS, INT(0), |
845 | "rec channels","stereo,mono",UNUSED}, | 845 | "rec channels","stereo,mono",UNUSED}, |
846 | CHOICE_SETTING(F_RECSETTING, rec_split_type, LANG_SPLIT_TYPE, 0, | 846 | CHOICE_SETTING(F_RECSETTING, rec_split_type, LANG_SPLIT_TYPE, 0, |
847 | "rec split type", "Split,Stop", NULL, 2, | 847 | "rec split type", "Split,Stop,Shutdown", NULL, 3, |
848 | ID2P(LANG_START_NEW_FILE), ID2P(LANG_STOP_RECORDING)), | 848 | ID2P(LANG_START_NEW_FILE), ID2P(LANG_STOP_RECORDING),ID2P(LANG_STOP_RECORDING_AND_SHUTDOWN)), |
849 | CHOICE_SETTING(F_RECSETTING, rec_split_method, LANG_SPLIT_MEASURE, 0, | 849 | CHOICE_SETTING(F_RECSETTING, rec_split_method, LANG_SPLIT_MEASURE, 0, |
850 | "rec split method", "Time,Filesize", NULL, 2, | 850 | "rec split method", "Time,Filesize", NULL, 2, |
851 | ID2P(LANG_TIME), ID2P(LANG_REC_SIZE)), | 851 | ID2P(LANG_TIME), ID2P(LANG_REC_SIZE)), |