# HG changeset patch # User Glenn Morris # Date 1242880808 0 # Node ID 9e868e938ebb34843b325720ca30b0be14b1bd71 # Parent fd266a506f8e75650a9147c3330f899a0f753cb0 (calendar-forward-day): Fix 2008-06-21 change - always move cursor to new date. (Bug#3338) diff -r fd266a506f8e -r 9e868e938ebb lisp/ChangeLog --- a/lisp/ChangeLog Wed May 20 15:14:20 2009 +0000 +++ b/lisp/ChangeLog Thu May 21 04:40:08 2009 +0000 @@ -1,3 +1,8 @@ +2009-05-21 Glenn Morris + + * calendar/cal-move.el (calendar-forward-day): Fix 2008-06-21 change - + always move cursor to new date. (Bug#3338) + 2009-05-20 Stefan Monnier * textmodes/tex-mode.el (tex-uptodate-p): Accept [1{/var/foo}] as diff -r fd266a506f8e -r 9e868e938ebb lisp/calendar/cal-move.el --- a/lisp/calendar/cal-move.el Wed May 20 15:14:20 2009 +0000 +++ b/lisp/calendar/cal-move.el Thu May 21 04:40:08 2009 +0000 @@ -230,14 +230,15 @@ (+ (calendar-absolute-from-gregorian cursor-date) arg))) (new-display-month (calendar-extract-month new-cursor-date)) (new-display-year (calendar-extract-year new-cursor-date))) - ;; Put the new month on the screen, if needed, and go to the new date. - (if (calendar-date-is-visible-p new-cursor-date) - (calendar-cursor-to-visible-date new-cursor-date) + ;; Put the new month on the screen, if needed. + (unless (calendar-date-is-visible-p new-cursor-date) ;; The next line gives smoother scrolling IMO (one month at a ;; time rather than two). (calendar-increment-month new-display-month new-display-year (if (< arg 0) 1 -1)) - (calendar-other-month new-display-month new-display-year)))) + (calendar-other-month new-display-month new-display-year)) + ;; Go to the new date. + (calendar-cursor-to-visible-date new-cursor-date))) (run-hooks 'calendar-move-hook)) ;;;###cal-autoload