From: Richard M. Stallman Date: Wed, 6 Feb 2002 15:00:31 +0000 (+0000) Subject: (rmail-toggle-header): Avoid possibly slow call to X-Git-Tag: ttn-vms-21-2-B4~16833 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9d43f6f103578fb139ce17ddac5f2c087d03baa7;p=emacs.git (rmail-toggle-header): Avoid possibly slow call to rmail-count-screen-lines starting from (point-min). --- diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el index 4d3d39d0f0d..2040fa2dad1 100644 --- a/lisp/mail/rmail.el +++ b/lisp/mail/rmail.el @@ -2058,12 +2058,7 @@ otherwise, show it in full." (recenter old-screen-line) (if (and all-headers-visible (not (= (window-start) (point-min)))) - (let ((lines-offscreen (rmail-count-screen-lines - (point-min) - (window-start window)))) - (recenter (min (+ old-screen-line lines-offscreen) - ;; last line of window - (- (window-height) 2)))))))))) + (recenter (- (window-height) 2)))))))) (rmail-highlight-headers)))) (defun rmail-narrow-to-non-pruned-header ()