(Electric-pop-up-window): Don't shrink the window if it's already big

enough.
This commit is contained in:
Chong Yidong 2008-10-29 21:42:37 +00:00
parent bb07cb70dd
commit 48238d1d45

View file

@ -153,8 +153,10 @@
(setq win (selected-window)))
(t
(switch-to-buffer buf)))
(fit-window-to-buffer win max-height)
;; Don't shrink the window, but expand it if necessary.
(goto-char (point-min))
(unless (= (point-max) (window-end win))
(fit-window-to-buffer win max-height))
win)))
(provide 'electric)