X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=emacs%2Fnotmuch-lib.el;h=e23999ad74a4dcbc29ec0c6fe0425c58b2c260a4;hb=ced341e82e8cb84dc2c90187d208838335511f6e;hp=61107e387a3f2382517ad5282311dc5cd0ea51fd;hpb=4f57e018431eefadda0157db05c7d84ead1bb1ae;p=notmuch diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el index 61107e38..e23999ad 100644 --- a/emacs/notmuch-lib.el +++ b/emacs/notmuch-lib.el @@ -435,9 +435,8 @@ of its command symbol." (insert desc))) (pop-to-buffer (help-buffer))))) -(defvar notmuch-buffer-refresh-function nil +(defvar-local notmuch-buffer-refresh-function nil "Function to call to refresh the current buffer.") -(make-variable-buffer-local 'notmuch-buffer-refresh-function) (defun notmuch-refresh-this-buffer () "Refresh the current buffer." @@ -534,14 +533,10 @@ This replaces spaces, percents, and double quotes in STR with (setq pred (cddr pred))) (cdr xplist))) -(defun notmuch-split-content-type (content-type) - "Split content/type into 'content' and 'type'." - (split-string content-type "/")) - (defun notmuch-match-content-type (t1 t2) "Return t if t1 and t2 are matching content types, taking wildcards into account." - (let ((st1 (notmuch-split-content-type t1)) - (st2 (notmuch-split-content-type t2))) + (let ((st1 (split-string t1 "/")) + (st2 (split-string t2 "/"))) (if (or (string= (cadr st1) "*") (string= (cadr st2) "*")) ;; Comparison of content types should be case insensitive. @@ -993,10 +988,7 @@ status." (find-file-noselect err-file)))) (when err-buffer (kill-buffer err-buffer)))) -;; This variable is used only buffer local, but it needs to be -;; declared globally first to avoid compiler warnings. -(defvar notmuch-show-process-crypto nil) -(make-variable-buffer-local 'notmuch-show-process-crypto) +(defvar-local notmuch-show-process-crypto nil) (defun notmuch-interactive-region () "Return the bounds of the current interactive region.