Move time_format pref to Horde
authorMichael M Slusarz <slusarz@curecanti.org>
Thu, 30 Sep 2010 20:02:23 +0000 (14:02 -0600)
committerMichael M Slusarz <slusarz@curecanti.org>
Thu, 30 Sep 2010 20:08:55 +0000 (14:08 -0600)
horde/config/prefs.php.dist
imp/config/prefs.php.dist
imp/docs/UPGRADING
kronolith/lib/Kronolith.php

index 5a6086d..94872e1 100644 (file)
@@ -314,7 +314,7 @@ $prefGroups['language'] = array(
     'desc' => _("Set your preferred language, timezone and date preferences."),
     'members' => array(
         'language', 'timezone', 'twentyFour', 'date_format',
-        'date_format_mini', 'first_week_day'
+        'date_format_mini', 'time_format', 'first_week_day'
     )
 );
 
@@ -403,6 +403,22 @@ $_prefs['date_format_mini'] = array(
     'desc' => _("Choose how to display dates (abbreviated format):"),
 );
 
+// Time format
+$_prefs['time_format'] = array(
+    'value' => '%X',
+    'type' => 'enum',
+    'enum' => array(
+        '%X' => strftime('%X'),
+        '%H:%M:%S' => strftime('%H:%M:%S'),
+        '%I:%M:%S %p' => strftime('%I:%M:%S %p'),
+        '%l:%M:%S %p' => strftime('%l:%M:%S %p'),
+        '%H:%M' => strftime('%H:%M'),
+        '%I:%M%p' => strftime('%I:%M%p'),
+        '%l:%M%p' => strftime('%l:%M%p'),
+    ),
+    'desc' => _("Choose how to display times:")
+);
+
 // what day should be displayed as the first day of the week?
 $_prefs['first_week_day'] = array(
     'value' => '0',
index c6ff87e..4b95072 100644 (file)
@@ -1199,7 +1199,7 @@ $prefGroups['mboxdisplay'] = array(
     'desc' => _("Change display preferences such as how many messages you see on each page and how messages are sorted."),
     'members' => array(
         'mailbox_start', 'sortby', 'sortdir', 'sortdate', 'max_msgs',
-        'from_link', 'time_format', 'atc_flag'
+        'from_link', 'atc_flag'
     )
 );
 
@@ -1287,20 +1287,6 @@ $_prefs['from_link'] = array(
     'desc' => _("The From: column of the message should be linked:")
 );
 
-// Time format for messages dated today
-$_prefs['time_format'] = array(
-    'value' => '%X',
-    'type' => 'enum',
-    'enum' => array(
-        '%X' => strftime('%X'),
-        '%H:%M:%S' => strftime('%H:%M:%S'),
-        '%I:%M:%S %p' => strftime('%I:%M:%S %p'),
-        '%H:%M' => strftime('%H:%M'),
-        '%I:%M%p' => strftime('%I:%M%p'),
-    ),
-    'desc' => _("Format of message dates in the mailbox view for messages dated today")
-);
-
 // Display attachment information in mailbox list.
 // Disabled by default, and not shown to user, because this display requires
 // substantial overhead to parse the message structures of all message in
index 0060dd4..29e6d6b 100644 (file)
@@ -66,6 +66,8 @@ The following configuration options have been removed:
 Preferences
 -----------
 
+The 'time_format' preference has been moved to Horde.
+
 The following preferences are no longer used and may be safely removed from
 your ``config/prefs.php`` file and your preferences backend::
 
index 567d783..95a1bbe 100644 (file)
@@ -152,7 +152,7 @@ class Kronolith
             'date_format' => str_replace(array('%e', '%d', '%a', '%A', '%m', '%h', '%b', '%B', '%y', '%Y'),
                                          array('d', 'dd', 'ddd', 'dddd', 'MM', 'MMM', 'MMM', 'MMMM', 'yy', 'yyyy'),
                                          Horde_Nls::getLangInfo(D_FMT)),
-            'time_format' => $prefs->getValue('twentyFour') ? 'HH:mm' : 'hh:mm tt',
+            'time_format' => $prefs->getValue('time_format'),
             'status' => array('tentative' => self::STATUS_TENTATIVE,
                               'confirmed' => self::STATUS_CONFIRMED,
                               'cancelled' => self::STATUS_CANCELLED,