diff options
Diffstat (limited to 'program/steps/mail')
-rw-r--r-- | program/steps/mail/compose.inc | 4 | ||||
-rw-r--r-- | program/steps/mail/func.inc | 13 | ||||
-rw-r--r-- | program/steps/mail/show.inc | 9 |
3 files changed, 11 insertions, 15 deletions
diff --git a/program/steps/mail/compose.inc b/program/steps/mail/compose.inc index 8f4bc9f9b..9fe4a686c 100644 --- a/program/steps/mail/compose.inc +++ b/program/steps/mail/compose.inc @@ -81,7 +81,7 @@ if (!is_array($_SESSION['compose']) || $_SESSION['compose']['id'] != get_input_v } // add some labels to client -rcube_add_label('nosubject', 'nosenderwarning', 'norecipientwarning', 'nosubjectwarning', 'nobodywarning', 'notsentwarning', 'savingmessage', 'sendingmessage', 'messagesaved', 'converting'); +$OUTPUT->add_label('nosubject', 'nosenderwarning', 'norecipientwarning', 'nosubjectwarning', 'nobodywarning', 'notsentwarning', 'savingmessage', 'sendingmessage', 'messagesaved', 'converting'); // add config parameter to client script $OUTPUT->set_env('draft_autosave', !empty($CONFIG['drafts_mbox']) ? $CONFIG['draft_autosave'] : 0); @@ -477,7 +477,7 @@ function rcmail_compose_body($attrib) $attrib['id'], JS_OBJECT_NAME), 'foot'); - rcube_add_label('checking'); + $OUTPUT->add_label('checking'); $OUTPUT->set_env('spellcheck_langs', join(',', $editor_lang_set)); } diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc index b7ef82ceb..a5ffb9d7b 100644 --- a/program/steps/mail/func.inc +++ b/program/steps/mail/func.inc @@ -69,19 +69,10 @@ if (empty($RCMAIL->action) || $RCMAIL->action == 'list') $OUTPUT->set_env('junk_mailbox', $CONFIG['junk_mbox']); if (!$OUTPUT->ajax_call) - rcube_add_label('checkingmail', 'deletemessage', 'movemessagetotrash', 'movingmessage'); + $OUTPUT->add_label('checkingmail', 'deletemessage', 'movemessagetotrash', 'movingmessage'); $OUTPUT->set_pagetitle(rcmail_localize_foldername($IMAP->get_mailbox_name())); } -else if ($RCMAIL->action == 'show') - { - // set current mailbox in client environment - $OUTPUT->set_env('mailbox', $IMAP->get_mailbox_name()); - if ($CONFIG['trash_mbox']) - $OUTPUT->set_env('trash_mailbox', $CONFIG['trash_mbox']); - if (!$OUTPUT->ajax_call) - rcube_add_label('checkingmail', 'deletemessage', 'movemessagetotrash', 'movingmessage'); - } /** @@ -99,7 +90,7 @@ function rcmail_message_list($attrib) $sort_order = $_SESSION['sort_order']; // add some labels to client - rcube_add_label('from', 'to'); + $OUTPUT->add_label('from', 'to'); // get message headers $a_headers = $IMAP->list_headers('', '', $sort_col, $sort_order); diff --git a/program/steps/mail/show.inc b/program/steps/mail/show.inc index 941c3cce2..d8478d569 100644 --- a/program/steps/mail/show.inc +++ b/program/steps/mail/show.inc @@ -71,11 +71,16 @@ if ($_GET['_uid']) { // give message uid to the client $OUTPUT->set_env('uid', $MESSAGE->uid); + // set environement $OUTPUT->set_env('safemode', $MESSAGE->is_safe); $OUTPUT->set_env('sender', $MESSAGE->sender['string']); $OUTPUT->set_env('permaurl', rcmail_url('show', array('_uid' => $MESSAGE->uid, '_mbox' => $mbox_name))); $OUTPUT->set_env('mailbox', $mbox_name); - + if ($CONFIG['trash_mbox']) + $OUTPUT->set_env('trash_mailbox', $CONFIG['trash_mbox']); + if (!$OUTPUT->ajax_call) + $OUTPUT->add_label('checkingmail', 'deletemessage', 'movemessagetotrash', 'movingmessage'); + // check for unset disposition notification if ($MESSAGE->headers->mdn_to && !$MESSAGE->headers->mdn_sent && @@ -92,7 +97,7 @@ if ($_GET['_uid']) { } else if (empty($CONFIG['mdn_requests'])) { - rcube_add_label('mdnrequest'); + $OUTPUT->add_label('mdnrequest'); $OUTPUT->set_env('mdn_request', true); } } |