emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] emacs/lisp/mail rmailsum.el


From: Glenn Morris
Subject: [Emacs-diffs] emacs/lisp/mail rmailsum.el
Date: Thu, 12 Feb 2009 03:28:38 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Glenn Morris <gm>       09/02/12 03:28:38

Modified files:
        lisp/mail      : rmailsum.el 

Log message:
        (rmail-get-summary-labels): Store any message labels for use in
        completion.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/mail/rmailsum.el?cvsroot=emacs&r1=1.166&r2=1.167

Patches:
Index: rmailsum.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/mail/rmailsum.el,v
retrieving revision 1.166
retrieving revision 1.167
diff -u -b -r1.166 -r1.167
--- rmailsum.el 7 Feb 2009 03:02:57 -0000       1.166
+++ rmailsum.el 12 Feb 2009 03:28:37 -0000      1.167
@@ -421,6 +421,8 @@
       (setq result (concat "{" result "}")))
     result))
 
+(autoload 'rmail-make-label "rmailkwd")
+
 (defun rmail-get-summary-labels ()
   "Return a string wrapped in curly braces with the current message labels.
 Returns nil if there are no labels.  The current buffer must
@@ -429,7 +431,10 @@
   (let ((labels (mail-fetch-field rmail-keyword-header)))
     (and labels
         (not (string-equal labels ""))
-        (format "{ %s } " labels))))
+        (progn
+          ;; Intern so that rmail-read-label can offer completion.
+          (mapc 'rmail-make-label (split-string labels ", "))
+          (format "{ %s } " labels)))))
 
 (defun rmail-create-summary (msgnum deleted unseen lines)
   "Return the summary line for message MSGNUM.




reply via email to

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