]> git.notmuchmail.org Git - notmuch/blobdiff - emacs/notmuch-jump.el
emacs: allow saved searches to select tree-view
[notmuch] / emacs / notmuch-jump.el
index 20e24b252630fe2992092cbeac8e8f606f27f1c9..506ae2c8e399785c9f56169a1f16589c5d3ad807 100644 (file)
@@ -54,7 +54,9 @@ fast way to jump to a saved search from anywhere in Notmuch."
                   (oldest-first t)
                   (otherwise (default-value 'notmuch-search-oldest-first)))))
            (push (list key name
-                       `(lambda () (notmuch-search ',query ',oldest-first)))
+                       (if (eq (plist-get saved-search :search-type) 'tree)
+                           `(lambda () (notmuch-tree ',query))
+                         `(lambda () (notmuch-search ',query ',oldest-first))))
                  action-map)))))
     (setq action-map (nreverse action-map))