X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=emacs%2Fnotmuch-tree.el;h=220c010dfbfa61e4f01d37961055176f69c1fa37;hb=8a20400490df27812780b349c1805e258cbac99c;hp=d5587a9c6351ca052f23311ae2c865f58ee2688d;hpb=d93e9cee13ef22c5dbba44f33357fd969b8ef88f;p=notmuch diff --git a/emacs/notmuch-tree.el b/emacs/notmuch-tree.el index d5587a9c..220c010d 100644 --- a/emacs/notmuch-tree.el +++ b/emacs/notmuch-tree.el @@ -258,6 +258,7 @@ FUNC." (define-key map (kbd "") (notmuch-tree-to-message-pane #'notmuch-show-previous-button)) (define-key map (kbd "TAB") (notmuch-tree-to-message-pane #'notmuch-show-next-button)) (define-key map "e" (notmuch-tree-to-message-pane #'notmuch-tree-button-activate)) + (define-key map "$" (notmuch-tree-to-message-pane #'notmuch-show-toggle-process-crypto)) ;; bindings from show (or elsewhere) but we close the message pane first. (define-key map "f" (notmuch-tree-close-message-pane-and #'notmuch-show-forward-message)) @@ -364,12 +365,18 @@ updated." (defun notmuch-tree-tag-update-display (&optional tag-changes) "Update display for TAG-CHANGES to current message. -Does NOT change the database." +Updates the message in the message pane if appropriate, but does +NOT change the database." (let* ((current-tags (notmuch-tree-get-tags)) - (new-tags (notmuch-update-tags current-tags tag-changes))) + (new-tags (notmuch-update-tags current-tags tag-changes)) + (tree-msg-id (notmuch-tree-get-message-id))) (unless (equal current-tags new-tags) (notmuch-tree-set-tags new-tags) - (notmuch-tree-refresh-result)))) + (notmuch-tree-refresh-result) + (when (window-live-p notmuch-tree-message-window) + (with-selected-window notmuch-tree-message-window + (when (string= tree-msg-id (notmuch-show-get-message-id)) + (notmuch-show-update-tags new-tags))))))) (defun notmuch-tree-tag (tag-changes) "Change tags for the current message"