Mercurial > emacs
changeset 1342:776d4c59f256
* rmail.el (rmail-first-unseen-message): Don't show the message,
just return its number, if there was an unseen message.
(rmail): Check for unseen messages before calling
rmail-get-new-mail. After getting the new mail, call
rmail-show-message to show the pre-existing unseen message, or if
that is nil, the current message, which rmail-get-new-mail sets to
the first new message.
author | Joseph Arceneaux <jla@gnu.org> |
---|---|
date | Mon, 05 Oct 1992 20:38:54 +0000 |
parents | dddbe06d2077 |
children | 9b5cb40cb6c8 |
files | lisp/mail/rmail.el |
diffstat | 1 files changed, 17 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/mail/rmail.el Mon Oct 05 19:03:02 1992 +0000 +++ b/lisp/mail/rmail.el Mon Oct 05 20:38:54 1992 +0000 @@ -201,10 +201,13 @@ (progn (rmail-set-message-counters) (rmail-show-message)))) - (rmail-get-new-mail) - ;; Show the first unseen message, which might be from a previous session - ;; or might have been just read in by rmail-get-new-mail. - (rmail-first-unseen-message))) + (let ((existing-unseen (rmail-first-unseen-message))) + (rmail-get-new-mail) + ;; Show the first unseen message, which might be from a previous session + ;; or might have been just read in by rmail-get-new-mail. Must + ;; determine already unseen messages first, as rmail-get-new-mail + ;; positions on the first new messsage, thus marking it as seen. + (rmail-show-message existing-unseen)))) ;; Given the value of MAILPATH, return a list of inbox file names. ;; This is turned off because it is not clear that the user wants @@ -1261,6 +1264,12 @@ (prefix-numeric-value current-prefix-arg)))) (rmail-search regexp (- (or n -1)))) +(defun glofp () + (interactive) + (let ((new (1+ (string-to-int (buffer-substring (1- (point)) (point)))))) + (backward-delete-char 1) + (insert (int-to-string new)))) + ;; Show the first message which has the `unseen' attribute. (defun rmail-first-unseen-message () (let ((current 1) @@ -1271,8 +1280,10 @@ (if (rmail-message-labels-p current ", ?\\(unseen\\),") (setq found current)) (setq current (1+ current)))) - (if found - (rmail-show-message found)))) +;; Let the caller show the message. +;; (if found +;; (rmail-show-message found)) + found)) ;;;; *** Rmail Message Deletion Commands ***