From f7335bf6cdb4a7aa7b80575a080d6c39b4a65dde Mon Sep 17 00:00:00 2001 From: djcb Date: Wed, 11 Apr 2012 18:26:50 +0300 Subject: [PATCH] * mu4e-hdrs.el: fix highlighting / automatic opening of messages when in the headers view --- emacs/mu4e-hdrs.el | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/emacs/mu4e-hdrs.el b/emacs/mu4e-hdrs.el index 3c9b570e..36a30864 100644 --- a/emacs/mu4e-hdrs.el +++ b/emacs/mu4e-hdrs.el @@ -773,8 +773,12 @@ docid. Otherwise, return nil." ;; is not visible (when docid (set-window-point (get-buffer-window mu4e-hdrs-buffer) (point)) - ;; attempt to highlight the new line - (mu4e-hdrs-highlight docid)) + ;; attempt to highlight the new line, display the message + (mu4e-hdrs-highlight docid) + ;; if there already is a visible message view, show the message + (when (and (buffer-live-p mu4e-view-buffer) + (window-live-p (get-buffer-window mu4e-view-buffer))) + (mu4e-view-message))) ;; return the docid only if the move succeeded (when succeeded docid)))) @@ -922,8 +926,6 @@ for draft messages." (defun mu4e-compose-new () "Compose a new message." (interactive) (mu4e-compose 'new)) - - ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (provide 'mu4e-hdrs)