summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog3
-rw-r--r--lisp/mail/rmail.el9
2 files changed, 8 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 029003c0429..c34ccb6e577 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -7,6 +7,9 @@
* mail/rmail.el (rmail-retry-ignored-headers): Add message-id.
(rmail-show-message-1): Preserve buffer modified flag.
+ (rmail-start-mail): Don't specify use of rmail-mail-return;
+ that's done by mail-bury now.
+ (rmail-mail-return): Handle arg NEWBUF.
2011-06-23 Michael Albinus <michael.albinus@gmx.de>
diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el
index 33f87d634a3..a0156aeb750 100644
--- a/lisp/mail/rmail.el
+++ b/lisp/mail/rmail.el
@@ -3458,15 +3458,15 @@ does not pop any summary buffer."
(if (stringp subject) (setq subject (rfc2047-decode-string subject)))
(prog1
(compose-mail to subject other-headers noerase
- switch-function yank-action sendactions
- '(rmail-mail-return))
+ switch-function yank-action sendactions)
(if (eq switch-function 'switch-to-buffer-other-frame)
;; This is not a standard frame parameter; nothing except
;; sendmail.el looks at it.
(modify-frame-parameters (selected-frame)
'((mail-dedicated-frame . t)))))))
-(defun rmail-mail-return ()
+(defun rmail-mail-return (&optional newbuf)
+ "NEWBUF is a buffer to switch to."
(cond
;; If there is only one visible frame with no special handling,
;; consider deleting the mail window to return to Rmail.
@@ -3491,7 +3491,8 @@ does not pop any summary buffer."
(if rmail-flag
;; If the Rmail buffer has a summary, show that.
(if summary-buffer (switch-to-buffer summary-buffer)
- (delete-window)))))
+ (delete-window))
+ (switch-to-buffer newbuf))))
;; If the frame was probably made for this buffer, the user
;; probably wants to delete it now.
((display-multi-frame-p)