From 0279c71a92cd54210b91e80541c0688fb55c3a19 Mon Sep 17 00:00:00 2001 From: Stéphane Doyon Date: Wed, 10 Oct 2007 01:41:48 +0000 Subject: Voice the recording trigger settings screen. From FS#6325, with a slight coding improvement. Also take out a duplicated snprintf in there. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15059 a1c6a512-1295-4272-9138-f99709370657 --- apps/recorder/recording.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'apps/recorder') diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c index ac06c93cf9..3b706e1a6d 100644 --- a/apps/recorder/recording.c +++ b/apps/recorder/recording.c @@ -123,11 +123,15 @@ static unsigned long rec_sizesplit_bytes(void) * Time strings used for the trigger durations. * Keep synchronous to trigger_times in settings_apply_trigger */ -const char * const trig_durations[TRIG_DURATION_COUNT] = +const struct opt_items trig_durations[TRIG_DURATION_COUNT] = { - "0s", "1s", "2s", "5s", - "10s", "15s", "20s", "25s", "30s", - "1min", "2min", "5min", "10min" +#define TS(x) { (unsigned char *)(#x "s"), TALK_ID(x, UNIT_SEC) } +#define TM(x) { (unsigned char *)(#x "min"), TALK_ID(x, UNIT_MIN) } + TS(0), TS(1), TS(2), TS(5), + TS(10), TS(15), TS(20), TS(25), TS(30), + TM(1), TM(2), TM(5), TM(10) +#undef TS +#undef TM }; void settings_apply_trigger(void) -- cgit v1.2.3