emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs/lisp ChangeLog mail/rmail.el


From: Glenn Morris
Subject: [Emacs-diffs] emacs/lisp ChangeLog mail/rmail.el
Date: Wed, 18 Feb 2009 08:02:59 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Glenn Morris <gm>       09/02/18 08:02:58

Modified files:
        lisp           : ChangeLog 
        lisp/mail      : rmail.el 

Log message:
        (rmail-get-new-mail-filter-spam): Show a message rather than the raw
        mbox while prompting.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/ChangeLog?cvsroot=emacs&r1=1.15348&r2=1.15349
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/mail/rmail.el?cvsroot=emacs&r1=1.508&r2=1.509

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.15348
retrieving revision 1.15349
diff -u -b -r1.15348 -r1.15349
--- ChangeLog   18 Feb 2009 07:41:10 -0000      1.15348
+++ ChangeLog   18 Feb 2009 08:02:56 -0000      1.15349
@@ -1,3 +1,9 @@
+2009-02-18  Glenn Morris  <address@hidden>
+
+       * mail/rmail.el (rmail-get-new-mail-filter-spam):
+       * mail/rmail-spam-filter.el (rmail-spam-filter):
+       Show a message rather than the raw mbox while prompting.
+
 2009-02-18  Martin Rudalics  <address@hidden>
 
        * progmodes/flymake.el (flymake): Add defgroup.  (Bug#2356)

Index: mail/rmail.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/mail/rmail.el,v
retrieving revision 1.508
retrieving revision 1.509
diff -u -b -r1.508 -r1.509
--- mail/rmail.el       18 Feb 2009 04:34:04 -0000      1.508
+++ mail/rmail.el       18 Feb 2009 08:02:58 -0000      1.509
@@ -1710,8 +1710,8 @@
        (message "%d new message%s read%s" new-messages suffix blurb)
        (unless (string-equal blurb "") ; there was spam
          (if rsf-beep (beep t))
-         ;; FIXME This doesn't seem a very good feature, e.g. it delays the
-         ;; appearance of the summary, and leaves the raw buffer visible.
+         ;; The use of rmail-show-message in rmail-get-new-mail-filter-spam
+         ;; also prevents the raw mbox buffer from showing at this point.
          (sleep-for rsf-sleep-after-message))
        ;; Establish the return value.
        (setq result (> new-messages 0))
@@ -1726,12 +1726,13 @@
       (or (rmail-spam-filter nscan)
          (setq nspam (1+ nspam)))
       (setq nscan (1+ nscan)))
-    ;; FIXME the expunge prompt leaves the raw mbox buffer showing,
-    ;; but it's not straightforward to show a message at this point
-    ;; without messing up the rest of get-new-mail.
-    (and (> nspam 0)
-        (rmail-expunge-confirmed)
-        (rmail-only-expunge t))
+    (when (> nspam 0)
+      ;; Otherwise the expunge prompt leaves the raw mbox buffer showing.
+      (rmail-show-message (rmail-first-unseen-message) 1)
+      (if (rmail-expunge-confirmed) (rmail-only-expunge t))
+      ;; Swap back, else get-new-mail-1 gets confused.
+      (rmail-swap-buffers-maybe)
+      (widen))
     ;; Return a message based on the number of spam messages found.
     (cond
      ((zerop nspam) "")




reply via email to

[Prev in Thread] Current Thread [Next in Thread]