# HG changeset patch # User Glenn Morris # Date 1231624892 0 # Node ID 8d9cf977e8f588f46a8aa86918309e038e357afd # Parent 38710cc3b8b510247617ae1960a68c5768f4c956 (calendar-scroll-left-three-months, calendar-scroll-right-three-months): Add event handling, for when called from menus with the calendar buffer not current. diff -r 38710cc3b8b5 -r 8d9cf977e8f5 lisp/ChangeLog --- a/lisp/ChangeLog Sat Jan 10 22:00:33 2009 +0000 +++ b/lisp/ChangeLog Sat Jan 10 22:01:32 2009 +0000 @@ -1,3 +1,13 @@ +2009-01-10 Glenn Morris + + * calendar/cal-move.el (calendar-scroll-left-three-months) + (calendar-scroll-right-three-months): + * calendar/holidays.el (calendar-list-holidays) + (calendar-mark-holidays): + * calendar/lunar.el (calendar-lunar-phases): + Add event handling, for when called from menus with the calendar buffer + not current. + 2009-01-10 Dan Nicolaescu * diff-mode.el (diff-show-trailing-whitespaces): Remove function. diff -r 38710cc3b8b5 -r 8d9cf977e8f5 lisp/calendar/cal-move.el --- a/lisp/calendar/cal-move.el Sat Jan 10 22:00:33 2009 +0000 +++ b/lisp/calendar/cal-move.el Sat Jan 10 22:01:32 2009 +0000 @@ -190,23 +190,27 @@ 'scroll-calendar-right 'calendar-scroll-right "23.1") ;;;###cal-autoload -(defun calendar-scroll-left-three-months (arg) +(defun calendar-scroll-left-three-months (arg &optional event) "Scroll the displayed calendar window left by 3*ARG months. If ARG is negative the calendar is scrolled right. Maintains the relative -position of the cursor with respect to the calendar as well as possible." - (interactive "p") - (calendar-scroll-left (* 3 arg))) +position of the cursor with respect to the calendar as well as possible. +EVENT is an event like `last-nonmenu-event'." + (interactive (list (prefix-numeric-value current-prefix-arg) + last-nonmenu-event)) + (calendar-scroll-left (* 3 arg) event)) (define-obsolete-function-alias 'scroll-calendar-left-three-months 'calendar-scroll-left-three-months "23.1") ;;;###cal-autoload -(defun calendar-scroll-right-three-months (arg) +(defun calendar-scroll-right-three-months (arg &optional event) "Scroll the displayed calendar window right by 3*ARG months. If ARG is negative the calendar is scrolled left. Maintains the relative -position of the cursor with respect to the calendar as well as possible." - (interactive "p") - (calendar-scroll-left (* -3 arg))) +position of the cursor with respect to the calendar as well as possible. +EVENT is an event like `last-nonmenu-event'." + (interactive (list (prefix-numeric-value current-prefix-arg) + last-nonmenu-event)) + (calendar-scroll-left (* -3 arg) event)) (define-obsolete-function-alias 'scroll-calendar-right-three-months 'calendar-scroll-right-three-months "23.1")