* mu4e-hdrs.el: fix highlighting / automatic opening of messages when in the

headers view
This commit is contained in:
djcb
2012-04-11 18:26:50 +03:00
parent 8c9a1b1e3f
commit f7335bf6cd

View File

@ -773,8 +773,12 @@ docid. Otherwise, return nil."
;; is not visible ;; is not visible
(when docid (when docid
(set-window-point (get-buffer-window mu4e-hdrs-buffer) (point)) (set-window-point (get-buffer-window mu4e-hdrs-buffer) (point))
;; attempt to highlight the new line ;; attempt to highlight the new line, display the message
(mu4e-hdrs-highlight docid)) (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 ;; return the docid only if the move succeeded
(when succeeded docid)))) (when succeeded docid))))
@ -922,8 +926,6 @@ for draft messages."
(defun mu4e-compose-new () (defun mu4e-compose-new ()
"Compose a new message." "Compose a new message."
(interactive) (mu4e-compose 'new)) (interactive) (mu4e-compose 'new))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(provide 'mu4e-hdrs) (provide 'mu4e-hdrs)