X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=emacs%2Fnotmuch-show.el;h=61a8c4cbd1e335c862cf8f5190044b54d35748b6;hb=ecdfa9a6b0d92ebc9bb0a41b597ad7420883d9ca;hp=904b98e1865fa7bfebadf1fa96b1b86419fe7a99;hpb=5c19eb46a906819744a022463ee3fd7cdfaabbb9;p=notmuch diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el index 904b98e1..61a8c4cb 100644 --- a/emacs/notmuch-show.el +++ b/emacs/notmuch-show.el @@ -470,7 +470,7 @@ message at DEPTH in the current thread." (new-start (button-start button)) (button-label (button-get button :base-label)) (old-point (point)) - (properties (text-properties-at (point))) + (properties (text-properties-at (button-start button))) (inhibit-read-only t)) ;; Toggle the button itself. (button-put button :notmuch-part-hidden (not show)) @@ -588,6 +588,10 @@ message at DEPTH in the current thread." ;; Render the primary part. (notmuch-show-insert-bodypart msg (car inner-parts) depth) + ;; Add hidden buttons for the rest + (mapc (lambda (inner-part) + (notmuch-show-insert-bodypart msg inner-part depth t)) + (cdr inner-parts)) (when notmuch-show-indent-multipart (indent-rigidly start (point) 1)))