summaryrefslogtreecommitdiff
path: root/lisp/minibuffer.el
diff options
context:
space:
mode:
authorJuri Linkov <juri@linkov.net>2014-12-27 02:54:56 +0200
committerJuri Linkov <juri@linkov.net>2014-12-27 02:54:56 +0200
commit162660c3639a68a7b71439bdd713d54f940274b8 (patch)
treea31f3c059fb337838244dddd60db42103120282e /lisp/minibuffer.el
parentd51459246bf54316f3a22694bf9eda0bfcc18a6a (diff)
downloademacs-162660c3639a68a7b71439bdd713d54f940274b8.tar.gz
Avoid duplicate calls of window-height in with-displayed-buffer-window
* lisp/minibuffer.el (minibuffer-completion-help): Use shrink-window-if-larger-than-buffer in window-height when temp-buffer-resize-mode is nil. * lisp/window.el (with-displayed-buffer-window): Remove window-height from the action alist in the temp-buffer-window-show call when window-height is handled explicitly afterwards. Fixes: debbugs:19355
Diffstat (limited to 'lisp/minibuffer.el')
-rw-r--r--lisp/minibuffer.el5
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el
index e1e6b0ee907..91989016067 100644
--- a/lisp/minibuffer.el
+++ b/lisp/minibuffer.el
@@ -1818,8 +1818,9 @@ variables.")
,(if (eq (selected-window) (minibuffer-window))
'display-buffer-at-bottom
'display-buffer-below-selected))
- ,(when temp-buffer-resize-mode
- '(window-height . resize-temp-buffer-window))
+ ,(if temp-buffer-resize-mode
+ '(window-height . resize-temp-buffer-window)
+ '(window-height . shrink-window-if-larger-than-buffer))
,(when temp-buffer-resize-mode
'(preserve-size . (nil . t))))
nil