mirror of https://github.com/djcb/mu.git
mu4e/view-gnus: Don't allow gnus-button-reply
Since it will reply in *gnus* rather than in mu4e. Perhaps we can hook it up with mu4e... but not now. Fixes: #1949.
This commit is contained in:
parent
2437dc27c9
commit
2fac2bb602
|
@ -116,8 +116,7 @@
|
||||||
((:subject :to :from :cc :bcc :from-or-to :date :attachments
|
((:subject :to :from :cc :bcc :from-or-to :date :attachments
|
||||||
:signature :decryption)) ; handled by Gnus
|
:signature :decryption)) ; handled by Gnus
|
||||||
(t
|
(t
|
||||||
(mu4e~view-gnus-insert-header-custom msg field))
|
(mu4e~view-gnus-insert-header-custom msg field)))))
|
||||||
)))
|
|
||||||
(let ((gnus-treatment-function-alist
|
(let ((gnus-treatment-function-alist
|
||||||
'((gnus-treat-highlight-headers
|
'((gnus-treat-highlight-headers
|
||||||
gnus-article-highlight-headers))))
|
gnus-article-highlight-headers))))
|
||||||
|
@ -161,11 +160,11 @@ with no charset."
|
||||||
(list handle attendee))
|
(list handle attendee))
|
||||||
handle-attendee))
|
handle-attendee))
|
||||||
|
|
||||||
;; We must neuter gnus-set-mode-line
|
|
||||||
(defun mu4e~view-nop (func &rest args)
|
(defun mu4e~view-nop (func &rest args)
|
||||||
"Do nothing."
|
"Do nothing when in mu4e-view-mode. This is useful for advising
|
||||||
;;(message "NOP %S %S %S %S" mu4e~view-mode major-mode func args)
|
some Gnus-functionality that does not work in mu4e."
|
||||||
(unless (derived-mode-p '(mu4e-view-mode))
|
(unless (or (eq major-mode 'mu4e-view-mode)
|
||||||
|
(derived-mode-p '(mu4e-view-mode)))
|
||||||
(apply func args)))
|
(apply func args)))
|
||||||
|
|
||||||
(defvar mu4e-view-mode-map
|
(defvar mu4e-view-mode-map
|
||||||
|
@ -363,8 +362,8 @@ Gnus' article-mode."
|
||||||
(define-key mu4e-view-mode-map (kbd "C-h b") 'describe-bindings)
|
(define-key mu4e-view-mode-map (kbd "C-h b") 'describe-bindings)
|
||||||
(setq mu4e~view-buffer-name gnus-article-buffer)
|
(setq mu4e~view-buffer-name gnus-article-buffer)
|
||||||
;; ;; turn off gnus modeline changes and menu items
|
;; ;; turn off gnus modeline changes and menu items
|
||||||
(when (fboundp 'gnus-set-mode-line)
|
(advice-add 'gnus-set-mode-line :around #'mu4e~view-nop)
|
||||||
(advice-add 'gnus-set-mode-line :around #'mu4e~view-nop))
|
(advice-add 'gnus-button-reply :around #'mu4e~view-nop)
|
||||||
(mu4e~view-mode-body))
|
(mu4e~view-mode-body))
|
||||||
|
|
||||||
(defun mu4e-view-message-text (msg)
|
(defun mu4e-view-message-text (msg)
|
||||||
|
|
Loading…
Reference in New Issue