From: Richard M. Stallman Date: Sun, 22 Mar 2009 14:51:17 +0000 (+0000) Subject: (rmail-expunge): Without DONT-SHOW, show the message even after X-Git-Tag: emacs-pretest-23.0.92~97 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8882002ae54e5a6b0d0acc4aa83caa8b4491fc39;p=emacs.git (rmail-expunge): Without DONT-SHOW, show the message even after updating summary. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 108cf01f152..01c01e10435 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,6 +1,8 @@ 2009-03-22 Richard M Stallman - * mail/rmail.el (rmail-expunge): Update summary buffer even if NO-SHOW. + * mail/rmail.el (rmail-expunge): Update summary buffer even if DONT-SHOW. + (rmail-expunge): Without DONT-SHOW, show the message even after + updating summary. 2009-03-21 Jari Aalto diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el index f39f7bf4636..4dfb7c8a1a2 100644 --- a/lisp/mail/rmail.el +++ b/lisp/mail/rmail.el @@ -3265,25 +3265,26 @@ See also user-option `rmail-confirm-expunge'." (interactive) (when (rmail-expunge-confirmed) (let ((was-deleted (rmail-message-deleted-p rmail-current-message)) - (was-swapped (rmail-buffers-swapped-p)) - (total rmail-total-messages)) + (was-swapped (rmail-buffers-swapped-p))) (rmail-only-expunge t) (if dont-show ;; Do update the summary buffer, if any. - (when (rmail-summary-exists) - (with-current-buffer rmail-summary-buffer - (let ((rmail-total-messages total)) - (rmail-update-summary)))) + (let ((total rmail-total-messages)) + (when (rmail-summary-exists) + (with-current-buffer rmail-summary-buffer + (let ((rmail-total-messages total)) + (rmail-update-summary))))) + ;; Update the summary and show it. (if (rmail-summary-exists) - (rmail-select-summary (rmail-update-summary)) - ;; If we expunged the current message, a new one is current now, - ;; so show it. If we weren't showing a message, show it. - (if (or was-deleted (not was-swapped)) - (rmail-show-message-1 rmail-current-message) - ;; Show the same message that was being shown before. - (rmail-display-labels) - (rmail-swap-buffers) - (setq rmail-buffer-swapped t))))))) + (rmail-select-summary (rmail-update-summary))) + ;; If we expunged the current message, a new one is current now, + ;; so show it. If we weren't showing a message, show it. + (if (or was-deleted (not was-swapped)) + (rmail-show-message-1 rmail-current-message) + ;; Show the same message that was being shown before. + (rmail-display-labels) + (rmail-swap-buffers) + (setq rmail-buffer-swapped t)))))) ;;;; *** Rmail Mailing Commands ***