From: Michael Olson Date: Wed, 8 Oct 2008 05:03:43 +0000 (+0000) Subject: ibuffer: Fix issue with ERC scroll-to-bottom (Bug #858). X-Git-Tag: emacs-pretest-23.0.90~2606 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=5412419465dbb3e12d0841ab15875fa34ca6f336;p=emacs.git ibuffer: Fix issue with ERC scroll-to-bottom (Bug #858). --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 34540d598d2..94ffd1fab54 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-10-08 Michael Olson + + * ibuffer.el (ibuffer-shrink-to-fit): Force redisplay, so that we + can avoid a bad interaction with programs that add functions to + the window-scroll-functions hook. This fixes Bug #858. + 2008-10-07 Chong Yidong * startup.el (command-line): Use display-warning to warn about an diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 539f88ec3c1..262f2ad73ab 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -1153,6 +1153,9 @@ a new window in the current frame, splitting vertically." (ibuffer-redisplay t))) (defun ibuffer-shrink-to-fit (&optional owin) + ;; Make sure that redisplay is performed, otherwise there can be a + ;; bad interaction with code in the window-scroll-functions hook + (redisplay t) (fit-window-to-buffer nil (when owin (/ (frame-height) (length (window-list (selected-frame)))))))