aboutsummaryrefslogtreecommitdiff
path: root/src/utils.c
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2013-10-03 21:50:28 +0000
committerTarmac <Unknown>2013-10-03 21:50:28 +0000
commit14a60879be70cc0779ef278e14b49565fce3d482 (patch)
tree29f151cc339fbef7f0b89491a07875bf58cda6c1 /src/utils.c
parent8b4e75ea9ce0a1f8c8be445dbde7de78a62b3caa (diff)
parentd9deaaaeb8c09db33539b498effe88b549d15b0f (diff)
downloadayatana-indicator-datetime-14a60879be70cc0779ef278e14b49565fce3d482.tar.gz
ayatana-indicator-datetime-14a60879be70cc0779ef278e14b49565fce3d482.tar.bz2
ayatana-indicator-datetime-14a60879be70cc0779ef278e14b49565fce3d482.zip
on the phone, show appointments at 1AM as '1 AM', clock times as '1:00 AM'. Fixes: https://bugs.launchpad.net/bugs/1220297.
Approved by PS Jenkins bot, Ted Gould.
Diffstat (limited to 'src/utils.c')
-rw-r--r--src/utils.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/utils.c b/src/utils.c
index bbb24ac..60fd393 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -294,6 +294,13 @@ get_terse_date_format_string (date_proximity_t proximity)
return fmt;
}
+const gchar*
+get_terse_header_time_format_string (void)
+{
+ /* a strftime(3) fmt string for a H:MM 12 hour time, eg "6:59 PM" */
+ return T_("%l:%M %p");
+}
+
const gchar *
get_terse_time_format_string (GDateTime * time)
{
@@ -301,8 +308,7 @@ get_terse_time_format_string (GDateTime * time)
if (g_date_time_get_minute (time) != 0)
{
- /* a strftime(3) fmt string for a H:MM 12 hour time, eg "6:59 PM" */
- fmt = T_("%l:%M %p");
+ fmt = get_terse_header_time_format_string ();
}
else
{