summaryrefslogtreecommitdiff
path: root/lisp/mail/mailabbrev.el
diff options
context:
space:
mode:
authorKatsumi Yamaoka <yamaoka@jpl.org>2012-12-06 03:30:23 +0000
committerKatsumi Yamaoka <yamaoka@jpl.org>2012-12-06 03:30:23 +0000
commit9ad948e2fdc7bbe7caa00fd3460ef3f47087c9c3 (patch)
treeff67d3cd8f7f34eafc01f9b3ef56af6a82a98b20 /lisp/mail/mailabbrev.el
parent9a81a97f1712feb7b6118e3513a671434bb3edb6 (diff)
downloademacs-9ad948e2fdc7bbe7caa00fd3460ef3f47087c9c3.tar.gz
Avoid letf macro use from Gnus
gnus/gmm-utils.el (gmm-flet): Remove. gnus/gnus-sync.el (gnus-sync-lesync-call): Avoid overriding json-alist-p. gnus/message.el (message-read-from-minibuffer): Avoid overriding mail-abbrev-in-expansion-header-p. mail/mailabbrev.el (mail-abbrev-expand-wrapper): Work in minibuffer so as to enable message-read-from-minibuffer to expand mail aliases.
Diffstat (limited to 'lisp/mail/mailabbrev.el')
-rw-r--r--lisp/mail/mailabbrev.el8
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/mail/mailabbrev.el b/lisp/mail/mailabbrev.el
index 2e4ffec1383..aa507897243 100644
--- a/lisp/mail/mailabbrev.el
+++ b/lisp/mail/mailabbrev.el
@@ -472,10 +472,12 @@ of a mail alias. The value is set up, buffer-local, when first needed.")
(defun mail-abbrev-expand-wrapper (expand)
(if (and mail-abbrevs (not (eq mail-abbrevs t)))
- (if (mail-abbrev-in-expansion-header-p)
+ (if (or (mail-abbrev-in-expansion-header-p)
+ ;; Necessary for `message-read-from-minibuffer' to work.
+ (window-minibuffer-p))
- ;; We are in a To: (or CC:, or whatever) header, and
- ;; should use word-abbrevs to expand mail aliases.
+ ;; We are in a To: (or CC:, or whatever) header or a minibuffer,
+ ;; and should use word-abbrevs to expand mail aliases.
(let ((local-abbrev-table mail-abbrevs))
;; Before anything else, resolve aliases if they need it.