X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=emacs%2Fnotmuch-jump.el;h=0193f8cd7064436efb73f13da4ea798668cbfef0;hp=05bbce5eaeadb8d8866749059c90b13b9d76e867;hb=5c4f6ed99bd10fa26162c46601714141adeb3fb5;hpb=f92342cb76fa3e1fa2f1c2e727f8ddf1a5c21b7d diff --git a/emacs/notmuch-jump.el b/emacs/notmuch-jump.el index 05bbce5e..0193f8cd 100644 --- a/emacs/notmuch-jump.el +++ b/emacs/notmuch-jump.el @@ -25,6 +25,10 @@ (require 'notmuch-lib) (require 'notmuch-hello) +(unless (fboundp 'window-body-width) + ;; Compatibility for Emacs pre-24 + (defalias 'window-body-width 'window-width)) + ;;;###autoload (defun notmuch-jump-search () "Jump to a saved search by shortcut key. @@ -47,7 +51,7 @@ fast way to jump to a saved search from anywhere in Notmuch." (case (plist-get saved-search :sort-order) (newest-first nil) (oldest-first t) - (otherwise (default-value notmuch-search-oldest-first))))) + (otherwise (default-value 'notmuch-search-oldest-first))))) (push (list key name `(lambda () (notmuch-search ',query ',oldest-first))) action-map))))) @@ -165,9 +169,3 @@ buffer." (setq notmuch-jump--action ',(third action)) (exit-minibuffer)))) map)) - -(unless (fboundp 'window-body-width) - ;; Compatibility for Emacs pre-24 - (defun window-body-width (&optional window) - (let ((edges (window-inside-edges window))) - (- (caddr edges) (car edges)))))