mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-13 18:17:39 -04:00
Fix speaking of decimal values to work when decimals != 1, spell the fractional part instead of speaking it like a number, break out a part of output_dyn_value into a separate function and use it
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17185 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
db2d61f4ea
commit
2521bf5d26
3 changed files with 32 additions and 19 deletions
|
@ -62,7 +62,7 @@ enum {
|
|||
#define TALK_ID(n,u) (((long)(u))<<UNIT_SHIFT | ((n) & ~(-1L<<UNIT_SHIFT)))
|
||||
|
||||
/* make a "talkable" ID from a decimal number + unit, the decimal number
|
||||
is represented like x*10*d where d is the number of decimal digits */
|
||||
is represented like x*10^d where d is the number of decimal digits */
|
||||
#define TALK_ID_DECIMAL(n,d,u) (((long)(u))<<UNIT_SHIFT |\
|
||||
((long)(d))<<DECIMAL_SHIFT |\
|
||||
((n) & ~(-1L<<DECIMAL_SHIFT)))
|
||||
|
@ -92,6 +92,9 @@ void talk_disable(bool disable); /* temporarily disable (or re-enable) talking (
|
|||
void talk_force_shutup(void); /* kill voice unconditionally */
|
||||
void talk_shutup(void); /* Interrupt voice, as when enqueue is false */
|
||||
|
||||
/* helper function for speaking fractional numbers */
|
||||
void talk_fractional(char *tbuf, int value, int unit);
|
||||
|
||||
#if CONFIG_RTC
|
||||
void talk_time(struct tm *tm, bool enqueue);
|
||||
void talk_date(struct tm *tm, bool enqueue);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue