disposition_send_mdn -> send_mdn
authorMichael M Slusarz <slusarz@curecanti.org>
Tue, 21 Dec 2010 01:59:57 +0000 (18:59 -0700)
committerMichael M Slusarz <slusarz@curecanti.org>
Tue, 21 Dec 2010 02:16:37 +0000 (19:16 -0700)
imp/config/prefs.php.dist
imp/docs/UPGRADING
imp/lib/LoginTasks/SystemTask/UpgradeFromImp4.php
imp/lib/Prefs/Ui.php
imp/lib/Ui/Message.php
imp/locale/en/help.xml

index 24e780f..3769b55 100644 (file)
@@ -708,7 +708,7 @@ $prefGroups['viewing'] = array(
         'image_replacement', 'image_addrbook', 'highlight_text',
         'highlight_simple_markup', 'show_quoteblocks', 'dim_signature',
         'emoticons', 'parts_display', 'mail_hdr', 'default_msg_charset',
-        'disposition_send_mdn'
+        'send_mdn'
     )
 );
 
@@ -838,7 +838,7 @@ $_prefs['default_msg_charset'] = array(
 );
 
 // Send read receipts?
-$_prefs['disposition_send_mdn'] = array(
+$_prefs['send_mdn'] = array(
     'value' => 1,
     'advanced' => true,
     'type' => 'enum',
@@ -850,7 +850,7 @@ $_prefs['disposition_send_mdn'] = array(
 //        2 => _("Prompt only if necessary; otherwise automatically send")
     ),
     'desc' => _("Prompt to send read receipt (a/k/a message disposition notification) when requested by the sender?"),
-    'help' => 'prefs-disposition_send_mdn'
+    'help' => 'prefs-send_mdn'
 );
 
 
index 12556dc..b88ece1 100644 (file)
@@ -74,6 +74,7 @@ your ``config/prefs.php`` file and your preferences backend::
    alternative_display
    attachment_display
    auto_delete_drafts
+   disposition_send_mdn
    fckeditor_buttons
    fetchmail_link
    fetchmail_menu
index 6114d6a..5ec8037 100644 (file)
@@ -132,6 +132,11 @@ class IMP_LoginTasks_SystemTask_UpgradeFromImp4 extends Horde_LoginTasks_SystemT
             ($prefs->getValue('initial_page') == 'folders.php')) {
             $prefs->setValue('initial_page', IMP_Prefs_Ui::PREF_FOLDER_PAGE);
         }
+
+        if ($prefs->isDefault('send_mdn') &&
+            $prefs->getValue('disposition_send_mdn')) {
+            $prefs->setValue('send_mdn', 1);
+        }
     }
 
     /**
index 9ab665c..689287f 100644 (file)
@@ -353,7 +353,7 @@ class IMP_Prefs_Ui
 
         case 'viewing':
             if (empty($conf['maillog']['use_maillog'])) {
-                $ui->suppress[] = 'disposition_send_mdn';
+                $ui->suppress[] = 'send_mdn';
             }
 
             $mock_part = new Horde_Mime_Part();
index 67a25a5..5a513c8 100644 (file)
@@ -71,7 +71,7 @@ class IMP_Ui_Message
     public function MDNCheck($mailbox, $uid, $headers, $confirmed = false)
     {
         $imp_imap = $GLOBALS['injector']->getInstance('IMP_Injector_Factory_Imap')->create();
-        $pref_val = $GLOBALS['prefs']->getValue('disposition_send_mdn');
+        $pref_val = $GLOBALS['prefs']->getValue('send_mdn');
 
         if (!$pref_val || $imp_imap->isReadOnly($mailbox)) {
             return false;
index 3b3ebfb..6c6b57c 100644 (file)
     </para>
 </entry>
 
-<entry id="prefs-disposition_send_mdn">
+<entry id="prefs-send_mdn">
     <title>Preferences: Send Read Receipt</title>
     <para>
     &quot;Send a MDN&quot; sends a read receipt (also known as a Message Disposition Notification) when you view a message in which the user has requested that they receive notification that you have read the message. By default, you will be prompted to send the notification.