summaryrefslogtreecommitdiff
path: root/program/steps/settings
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-05-08 14:28:36 +0200
committerAleksander Machniak <alec@alec.pl>2013-05-08 14:28:36 +0200
commita522971cf853b2f0ccd1b569491a06218ebbaee9 (patch)
treecf0e8c6bbe0978cf302b112080370b9a01cf5900 /program/steps/settings
parentea6d6958e0a32c88bf8c00cbd118cfcd48fae096 (diff)
parentc4723999e21da0b266b0467de6e58cbd26c4b5bf (diff)
Merge branch 'master' of github.com:roundcube/roundcubemail
Conflicts: program/js/list.js
Diffstat (limited to 'program/steps/settings')
-rw-r--r--program/steps/settings/edit_prefs.inc2
-rw-r--r--program/steps/settings/folders.inc3
-rw-r--r--program/steps/settings/func.inc11
-rw-r--r--program/steps/settings/save_prefs.inc1
4 files changed, 14 insertions, 3 deletions
diff --git a/program/steps/settings/edit_prefs.inc b/program/steps/settings/edit_prefs.inc
index 971ed60b6..468e4994d 100644
--- a/program/steps/settings/edit_prefs.inc
+++ b/program/steps/settings/edit_prefs.inc
@@ -40,7 +40,7 @@ function rcmail_user_prefs_form($attrib)
$out = $form_start;
- foreach ($SECTIONS[$CURR_SECTION]['blocks'] as $idx => $block) {
+ foreach ($SECTIONS[$CURR_SECTION]['blocks'] as $block) {
if (!empty($block['options'])) {
$table = new html_table(array('cols' => 2));
diff --git a/program/steps/settings/folders.inc b/program/steps/settings/folders.inc
index 0c7d9063f..34a72dd95 100644
--- a/program/steps/settings/folders.inc
+++ b/program/steps/settings/folders.inc
@@ -283,7 +283,6 @@ function rcube_subscription_form($attrib)
$noselect = false;
$classes = array($i%2 ? 'even' : 'odd');
- $folder_js = Q($folder['id']);
$folder_utf8 = rcube_charset_convert($folder['id'], 'UTF7-IMAP');
$display_folder = str_repeat('&nbsp;&nbsp;&nbsp;&nbsp;', $folder['level'])
. Q($protected ? rcmail_localize_foldername($folder['id']) : $folder['name']);
@@ -394,7 +393,7 @@ function rcmail_rename_folder($oldname, $newname)
$a_threaded = (array) $RCMAIL->config->get('message_threading', array());
$oldprefix = '/^' . preg_quote($oldname . $delimiter, '/') . '/';
- foreach ($a_threaded as $key => $val) {
+ foreach (array_keys($a_threaded) as $key) {
if ($key == $oldname) {
unset($a_threaded[$key]);
$a_threaded[$newname] = true;
diff --git a/program/steps/settings/func.inc b/program/steps/settings/func.inc
index 319c58db9..860f36c35 100644
--- a/program/steps/settings/func.inc
+++ b/program/steps/settings/func.inc
@@ -418,6 +418,17 @@ function rcmail_user_prefs($current=null)
);
}
+ // show checkbox to show email instead of name
+ if (!isset($no_override['message_show_email'])) {
+ $field_id = 'rcmfd_message_show_email';
+ $input_msgshowemail = new html_checkbox(array('name' => '_message_show_email', 'id' => $field_id, 'value' => 1));
+
+ $blocks['main']['options']['message_show_email'] = array(
+ 'title' => html::label($field_id, Q(rcube_label('showemail'))),
+ 'content' => $input_msgshowemail->show($config['message_show_email']?1:0),
+ );
+ }
+
// show checkbox for HTML/plaintext messages
if (!isset($no_override['prefer_html'])) {
$field_id = 'rcmfd_htmlmsg';
diff --git a/program/steps/settings/save_prefs.inc b/program/steps/settings/save_prefs.inc
index dfb2b13ac..3bb82aa38 100644
--- a/program/steps/settings/save_prefs.inc
+++ b/program/steps/settings/save_prefs.inc
@@ -60,6 +60,7 @@ switch ($CURR_SECTION)
case 'mailview':
$a_user_prefs = array(
'message_extwin' => intval($_POST['_message_extwin']),
+ 'message_show_email' => isset($_POST['_message_show_email']) ? TRUE : FALSE,
'prefer_html' => isset($_POST['_prefer_html']) ? TRUE : FALSE,
'inline_images' => isset($_POST['_inline_images']) ? TRUE : FALSE,
'show_images' => isset($_POST['_show_images']) ? intval($_POST['_show_images']) : 0,