diff options
Diffstat (limited to 'apps/recorder')
-rw-r--r-- | apps/recorder/keyboard.c | 10 | ||||
-rw-r--r-- | apps/recorder/recording.c | 18 |
2 files changed, 14 insertions, 14 deletions
diff --git a/apps/recorder/keyboard.c b/apps/recorder/keyboard.c index 5c97f2bad6..3ce0208b7e 100644 --- a/apps/recorder/keyboard.c +++ b/apps/recorder/keyboard.c | |||
@@ -190,7 +190,7 @@ static void kbd_spellchar(unsigned short c) | |||
190 | { | 190 | { |
191 | static char spell_char[2] = "\0\0"; /* store char to pass to talk_spell */ | 191 | static char spell_char[2] = "\0\0"; /* store char to pass to talk_spell */ |
192 | 192 | ||
193 | if (global_settings.talk_menu && c < 128) /* voice UI? */ | 193 | if (talk_menus_enabled() && c < 128) /* voice UI? */ |
194 | { | 194 | { |
195 | spell_char[0] = (char)c; | 195 | spell_char[0] = (char)c; |
196 | talk_spell(spell_char, false); | 196 | talk_spell(spell_char, false); |
@@ -510,7 +510,7 @@ int kbd_input(char* text, int buflen) | |||
510 | /* Initial edit position is after last character */ | 510 | /* Initial edit position is after last character */ |
511 | editpos = utf8length(text); | 511 | editpos = utf8length(text); |
512 | 512 | ||
513 | if (global_settings.talk_menu) /* voice UI? */ | 513 | if (talk_menus_enabled()) /* voice UI? */ |
514 | talk_spell(text, true); /* spell initial text */ | 514 | talk_spell(text, true); /* spell initial text */ |
515 | 515 | ||
516 | action_signalscreenchange(); | 516 | action_signalscreenchange(); |
@@ -1087,7 +1087,7 @@ int kbd_input(char* text, int buflen) | |||
1087 | kbd_inschar(text, buflen, &editpos, ch); | 1087 | kbd_inschar(text, buflen, &editpos, ch); |
1088 | } | 1088 | } |
1089 | 1089 | ||
1090 | if (global_settings.talk_menu) /* voice UI? */ | 1090 | if (talk_menus_enabled()) /* voice UI? */ |
1091 | talk_spell(text, false); | 1091 | talk_spell(text, false); |
1092 | 1092 | ||
1093 | /* speak revised text */ | 1093 | /* speak revised text */ |
@@ -1116,7 +1116,7 @@ int kbd_input(char* text, int buflen) | |||
1116 | kbd_inschar(text, buflen, &editpos, ch); | 1116 | kbd_inschar(text, buflen, &editpos, ch); |
1117 | } | 1117 | } |
1118 | 1118 | ||
1119 | if (global_settings.talk_menu) /* voice UI? */ | 1119 | if (talk_menus_enabled()) /* voice UI? */ |
1120 | talk_spell(text, false); /* speak revised text */ | 1120 | talk_spell(text, false); /* speak revised text */ |
1121 | break; | 1121 | break; |
1122 | 1122 | ||
@@ -1167,7 +1167,7 @@ int kbd_input(char* text, int buflen) | |||
1167 | param[l].hangul = false; | 1167 | param[l].hangul = false; |
1168 | kbd_inschar(text, buflen, &editpos, morse_alphabets[j]); | 1168 | kbd_inschar(text, buflen, &editpos, morse_alphabets[j]); |
1169 | 1169 | ||
1170 | if (global_settings.talk_menu) /* voice UI? */ | 1170 | if (talk_menus_enabled()) /* voice UI? */ |
1171 | talk_spell(text, false); /* speak revised text */ | 1171 | talk_spell(text, false); /* speak revised text */ |
1172 | } | 1172 | } |
1173 | #endif /* KBD_MORSE_INPUT */ | 1173 | #endif /* KBD_MORSE_INPUT */ |
diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c index 226ff9a17f..f7ceb508d5 100644 --- a/apps/recorder/recording.c +++ b/apps/recorder/recording.c | |||
@@ -705,7 +705,6 @@ bool recording_screen(bool no_source) | |||
705 | int radio_status = (global_settings.rec_source != AUDIO_SRC_FMRADIO) ? | 705 | int radio_status = (global_settings.rec_source != AUDIO_SRC_FMRADIO) ? |
706 | FMRADIO_OFF : get_radio_status(); | 706 | FMRADIO_OFF : get_radio_status(); |
707 | #endif | 707 | #endif |
708 | int talk_menu = global_settings.talk_menu; | ||
709 | #if (CONFIG_LED == LED_REAL) | 708 | #if (CONFIG_LED == LED_REAL) |
710 | bool led_state = false; | 709 | bool led_state = false; |
711 | int led_countdown = 2; | 710 | int led_countdown = 2; |
@@ -741,9 +740,8 @@ bool recording_screen(bool no_source) | |||
741 | #endif | 740 | #endif |
742 | 741 | ||
743 | #if CONFIG_CODEC == SWCODEC | 742 | #if CONFIG_CODEC == SWCODEC |
744 | /* recording_menu gets messed up: so reset talk_menu */ | 743 | /* recording_menu gets messed up: so prevent manus talking */ |
745 | talk_menu = global_settings.talk_menu; | 744 | talk_disable_menus(); |
746 | global_settings.talk_menu = 0; | ||
747 | /* audio_init_recording stops anything playing when it takes the audio | 745 | /* audio_init_recording stops anything playing when it takes the audio |
748 | buffer */ | 746 | buffer */ |
749 | #else | 747 | #else |
@@ -931,8 +929,9 @@ bool recording_screen(bool no_source) | |||
931 | have_recorded = true; | 929 | have_recorded = true; |
932 | rec_record(); | 930 | rec_record(); |
933 | last_seconds = 0; | 931 | last_seconds = 0; |
934 | if (talk_menu) | 932 | if (global_settings.talk_menu) |
935 | { /* no voice possible here, but a beep */ | 933 | { |
934 | /* no voice possible here, but a beep */ | ||
936 | audio_beep(HZ/2); /* longer beep on start */ | 935 | audio_beep(HZ/2); /* longer beep on start */ |
937 | } | 936 | } |
938 | } | 937 | } |
@@ -960,8 +959,9 @@ bool recording_screen(bool no_source) | |||
960 | if(audio_stat & AUDIO_STATUS_PAUSE) | 959 | if(audio_stat & AUDIO_STATUS_PAUSE) |
961 | { | 960 | { |
962 | audio_resume_recording(); | 961 | audio_resume_recording(); |
963 | if (talk_menu) | 962 | if (global_settings.talk_menu) |
964 | { /* no voice possible here, but a beep */ | 963 | { |
964 | /* no voice possible here, but a beep */ | ||
965 | audio_beep(HZ/4); /* short beep on resume */ | 965 | audio_beep(HZ/4); /* short beep on resume */ |
966 | } | 966 | } |
967 | } | 967 | } |
@@ -1695,7 +1695,7 @@ bool recording_screen(bool no_source) | |||
1695 | rec_set_source(AUDIO_SRC_PLAYBACK, SRCF_PLAYBACK); | 1695 | rec_set_source(AUDIO_SRC_PLAYBACK, SRCF_PLAYBACK); |
1696 | 1696 | ||
1697 | /* restore talk_menu setting */ | 1697 | /* restore talk_menu setting */ |
1698 | global_settings.talk_menu = talk_menu; | 1698 | talk_enable_menus(); |
1699 | #else /* !SWCODEC */ | 1699 | #else /* !SWCODEC */ |
1700 | audio_init_playback(); | 1700 | audio_init_playback(); |
1701 | #endif /* CONFIG_CODEC == SWCODEC */ | 1701 | #endif /* CONFIG_CODEC == SWCODEC */ |