Index: rockbox-devel/apps/filetree.c
===================================================================
--- rockbox-devel.orig/apps/filetree.c
+++ rockbox-devel/apps/filetree.c
@@ -323,7 +323,7 @@ int ft_load(struct tree_context* c, cons
/* If thumbnail talking is enabled, make an extra run to mark files with
associated thumbnails, so we don't do unsuccessful spinups later. */
- if (global_settings.talk_file == 3)
+ if (global_settings.talk_file >= 3)
check_file_thumbnails(c); /* map .talk to ours */
return 0;
Index: rockbox-devel/apps/lang/english.lang
===================================================================
--- rockbox-devel.orig/apps/lang/english.lang
+++ rockbox-devel/apps/lang/english.lang
@@ -10100,3 +10100,31 @@
*: "Track lock step"
+
+ id: LANG_VOICE_DIR_HOVER_ELSE_NUMBERS
+ desc: "talkbox" mode for directories + files
+ user:
+
+ *: ".talk mp3 clip, fallback numbers"
+
+
+ *: ".talk mp3 clip, fallback numbers"
+
+
+ *: "talk mp3 clip, fallback numbers"
+
+
+
+ id: LANG_VOICE_DIR_HOVER_ELSE_SPELL
+ desc: "talkbox" mode for directories + files
+ user:
+
+ *: ".talk mp3 clip, fallback spell"
+
+
+ *: ".talk mp3 clip, fallback spell"
+
+
+ *: "talk mp3 clip, fallback spell"
+
+
Index: rockbox-devel/apps/settings_menu.c
===================================================================
--- rockbox-devel.orig/apps/settings_menu.c
+++ rockbox-devel/apps/settings_menu.c
@@ -1303,13 +1303,14 @@ static const struct opt_items voice_name
{ STR(LANG_OFF) },
{ STR(LANG_VOICE_NUMBER) },
{ STR(LANG_VOICE_SPELL) },
- { STR(LANG_VOICE_DIR_HOVER) }
+ { STR(LANG_VOICE_DIR_HOVER_ELSE_NUMBERS) },
+ { STR(LANG_VOICE_DIR_HOVER_ELSE_SPELL) }
};
static bool voice_dirs(void)
{
bool ret = set_option( str(LANG_VOICE_DIR),
- &global_settings.talk_dir, INT, voice_names, 4, NULL);
+ &global_settings.talk_dir, INT, voice_names, 5, NULL);
#if CONFIG_CODEC == SWCODEC
audio_set_crossfade(global_settings.crossfade);
#endif
@@ -1322,11 +1323,11 @@ static bool voice_files(void)
bool ret;
ret = set_option( str(LANG_VOICE_FILE),
- &global_settings.talk_file, INT, voice_names, 4, NULL);
+ &global_settings.talk_file, INT, voice_names, 5, NULL);
#if CONFIG_CODEC == SWCODEC
audio_set_crossfade(global_settings.crossfade);
#endif
- if (oldval != 3 && global_settings.talk_file == 3)
+ if (oldval < 3 && global_settings.talk_file >= 3)
{ /* force reload if newly talking thumbnails,
because the clip presence is cached only if enabled */
reload_directory();
Index: rockbox-devel/apps/talk.c
===================================================================
--- rockbox-devel.orig/apps/talk.c
+++ rockbox-devel/apps/talk.c
@@ -534,8 +534,8 @@ void talk_init(void)
bool talk_voice_required(void)
{
return (voicefile_size != 0) /* Voice file is available */
- || (global_settings.talk_dir == 3) /* Thumbnail clips are required */
- || (global_settings.talk_file == 3);
+ || (global_settings.talk_dir >= 3) /* Thumbnail clips are required */
+ || (global_settings.talk_file >= 3);
}
/* return size of voice file */
Index: rockbox-devel/apps/tree.c
===================================================================
--- rockbox-devel.orig/apps/tree.c
+++ rockbox-devel/apps/tree.c
@@ -859,9 +859,18 @@ static bool dirbrowse(void)
DEBUGF("Playing directory thumbnail: %s", currdir);
res = ft_play_dirname(name);
if (res < 0) /* failed, not existing */
- { /* say the number instead, as a fallback */
- talk_id(VOICE_DIR, false);
- talk_number(lasti+1, true);
+ {
+ switch (global_settings.talk_dir) {
+ case 3: /* say the number instead */
+ talk_id(VOICE_DIR, false);
+ talk_number(lasti+1, true);
+ break;
+ case 4: /* spell the name instead */
+ talk_spell(name, false);
+ break;
+ default:
+ break;
+ }
}
}
else
@@ -1011,6 +1020,7 @@ static bool dirbrowse(void)
break;
case 3: /* thumbnail clip */
+ case 4:
/* "schedule" a thumbnail, to have a little
delay */
thumbnail_time = current_tick + HOVER_DELAY;
@@ -1034,13 +1044,18 @@ static bool dirbrowse(void)
break;
case 3: /* thumbnail clip */
+ case 4:
/* "schedule" a thumbnail, to have a little
delay */
if (attr & TREE_ATTR_THUMBNAIL)
thumbnail_time = current_tick + HOVER_DELAY;
- else
- /* spell the number as fallback */
- talk_spell(name, false);
+ else if(global_settings.talk_file == 3)
+ { /* say the number as fallback */
+ talk_id(VOICE_FILE, false);
+ talk_number(lasti+1, true);
+ }
+ else /* say the name as fallback */
+ talk_spell(name, false);
break;
default:
Index: rockbox-devel/apps/settings.c
===================================================================
--- rockbox-devel.orig/apps/settings.c
+++ rockbox-devel/apps/settings.c
@@ -459,8 +459,8 @@ static const struct bit_entry hd_bits[]
{1, S_O(line_in), false, "line in", off_on },
#endif
/* voice */
- {2, S_O(talk_dir), 0, "talk dir", off_number_spell_hover },
- {2, S_O(talk_file), 0, "talk file", off_number_spell_hover },
+ {3, S_O(talk_dir), 0, "talk dir", off_number_spell_hover },
+ {3, S_O(talk_file), 0, "talk file", off_number_spell_hover },
{1, S_O(talk_menu), true, "talk menu", off_on },
{2, S_O(sort_file), 0, "sort files", "alpha,oldest,newest,type" },