+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'left_refresh',
+ 'caption' => _("Auto Refresh Folder List"),
+ 'type' => SMOPT_TYPE_STRLIST,
+ 'refresh' => SMOPT_REFRESH_FOLDERLIST,
+ 'posvals' => $left_refresh_values
+ );
+
+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'unseen_notify',
+ 'caption' => _("Enable Unread Message Notification"),
+ 'type' => SMOPT_TYPE_STRLIST,
+ 'refresh' => SMOPT_REFRESH_FOLDERLIST,
+ 'posvals' => array(SMPREF_UNSEEN_NONE => _("No Notification"),
+ SMPREF_UNSEEN_INBOX => _("Only INBOX"),
+ SMPREF_UNSEEN_ALL => _("All Folders"))
+ );
+
+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'unseen_type',
+ 'caption' => _("Unread Message Notification Type"),
+ 'type' => SMOPT_TYPE_STRLIST,
+ 'refresh' => SMOPT_REFRESH_FOLDERLIST,
+ 'posvals' => array(SMPREF_UNSEEN_ONLY => _("Only Unseen"),
+ SMPREF_UNSEEN_TOTAL => _("Unseen and Total"))
+ );
+
+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'collapse_folders',
+ 'caption' => _("Enable Collapsable Folders"),
+ 'type' => SMOPT_TYPE_BOOLEAN,
+ 'refresh' => SMOPT_REFRESH_FOLDERLIST
+ );
+
+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'date_format',
+ 'caption' => _("Show Clock on Folders Panel"),
+ 'type' => SMOPT_TYPE_STRLIST,
+ 'refresh' => SMOPT_REFRESH_FOLDERLIST,
+ 'posvals' => array( '1' => 'MM/DD/YY HH:MM',
+ '2' => 'DD/MM/YY HH:MM',
+ '3' => 'DDD, HH:MM',
+ '4' => 'HH:MM:SS',
+ '5' => 'HH:MM',
+ '6' => _("No Clock")),
+ );
+
+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'hour_format',
+ 'caption' => _("Hour Format"),
+ 'type' => SMOPT_TYPE_STRLIST,
+ 'refresh' => SMOPT_REFRESH_FOLDERLIST,
+ 'posvals' => array(SMPREF_TIME_12HR => _("12-hour clock"),
+ SMPREF_TIME_24HR => _("24-hour clock"))
+ );
+
+ $optvals[SMOPT_GRP_FOLDERLIST][] = array(
+ 'name' => 'search_memory',
+ 'caption' => _("Memory Search"),
+ 'type' => SMOPT_TYPE_STRLIST,
+ 'refresh' => SMOPT_REFRESH_NONE,
+ 'posvals' => array( 0 => _("Disabled"),
+ 1 => '1',
+ 2 => '2',
+ 3 => '3',
+ 4 => '4',
+ 5 => '5',
+ 6 => '6',
+ 7 => '7',
+ 8 => '8',
+ 9 => '9')
+ );
+
+ /* Assemble all this together and return it as our result. */
+ $result = array(
+ 'grps' => $optgrps,
+ 'vals' => $optvals
+ );
+ return ($result);
+}
+
+/******************************************************************/
+/** Define any specialized save functions for this option page. ***/
+/******************************************************************/
+function save_option_trash_folder($option) {
+ global $data_dir, $username;
+
+ /* Set move to trash on or off. */
+ $trash_on = ($option->new_value == SMPREF_NONE ? SMPREF_OFF : SMPREF_ON);
+ setPref($data_dir, $username, 'move_to_trash', $trash_on);
+
+ /* Now just save the option as normal. */
+ save_option($option);
+}
+
+function save_option_sent_folder($option) {
+ global $data_dir, $username;