[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v |
Date: |
Sat, 08 Mar 2008 21:04:34 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Glenn Morris <gm> 08/03/08 21:04:33
Index: cal-menu.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/calendar/cal-menu.el,v
retrieving revision 1.84
retrieving revision 1.85
diff -u -b -r1.84 -r1.85
--- cal-menu.el 7 Mar 2008 04:45:09 -0000 1.84
+++ cal-menu.el 8 Mar 2008 21:04:33 -0000 1.85
@@ -116,6 +116,7 @@
["Yearly" insert-yearly-hebrew-diary-entry])))
(defun cal-menu-holiday-window-suffix ()
+ "Return a string suffix for the \"Window\" entry in
`cal-menu-holidays-menu'."
(let ((my1 (calendar-increment-month -1))
(my2 (calendar-increment-month 1)))
(if (= (cdr my1) (cdr my2))
@@ -200,8 +201,8 @@
["Backward 1 Year" "4\ev"]))
(defun cal-menu-x-popup-menu (position menu)
- "Like `x-popup-menu', but prints an error message if popup menus are
-not available."
+ "Like `x-popup-menu', but print an error message if popups are unavailable.
+POSITION and MENU are passed to `x-popup-menu'."
(if (display-popup-menus-p)
(x-popup-menu position menu)
(error "Popup menus are not available on this system")))
@@ -251,7 +252,8 @@
(autoload 'diary-list-entries "diary-lib")
(defun calendar-mouse-holidays (&optional event)
- "Pop up menu of holidays for mouse selected date."
+ "Pop up menu of holidays for mouse selected date.
+EVENT is the event that invoked this command."
(interactive "e")
(let* ((date (calendar-event-to-date))
(l (mapcar 'list (calendar-check-holidays date)))
@@ -269,9 +271,9 @@
(defun calendar-mouse-view-diary-entries (&optional date diary event)
"Pop up menu of diary entries for mouse-selected date.
-Use optional DATE and alternative file DIARY.
-
-Any holidays are shown if `holidays-in-diary-buffer' is t."
+Use optional DATE and alternative file DIARY. EVENT is the event
+that invoked this command. Shows holidays if `holidays-in-diary-buffer'
+is non-nil."
(interactive "i\ni\ne")
(let* ((date (or date (calendar-event-to-date)))
(diary-file (if diary diary diary-file))
@@ -418,7 +420,8 @@
(cal-tex-cursor-year-landscape nil)))
(defun calendar-mouse-print-dates (&optional event)
- "Pop up menu of equivalent dates to mouse selected date."
+ "Pop up menu of equivalent dates to mouse selected date.
+EVENT is the event that invoked this command."
(interactive "e")
(let* ((date (calendar-event-to-date))
(selection
@@ -476,9 +479,15 @@
(calendar-print-chinese-date)))
(defun calendar-mouse-goto-date (date)
+ "Goto DATE in the buffer specified by `last-input-event'."
(set-buffer (window-buffer (posn-window (event-start last-input-event))))
(calendar-goto-date date))
+(defun cal-menu-set-date-title (menu)
+ "Convert date of last event to title suitable for MENU."
+ (easy-menu-filter-return
+ menu (calendar-date-string (calendar-event-to-date t) t nil)))
+
(easy-menu-define cal-menu-context-mouse-menu nil
"Pop up menu for Mouse-2 for selected date in the calendar window."
'("foo" :filter cal-menu-set-date-title
@@ -506,10 +515,6 @@
["Insert diary entry" calendar-mouse-insert-diary-entry]
["Other diary file entries" calendar-mouse-view-other-diary-entries]))
-(defun cal-menu-set-date-title (menu)
- (easy-menu-filter-return
- menu (calendar-date-string (calendar-event-to-date t) t nil)))
-
(easy-menu-define cal-menu-global-mouse-menu nil
"Menu bound to a mouse event, not specific to the mouse-click location."
'("Calendar"
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/06
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v,
Glenn Morris <=
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/13
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/13
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/14
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/20
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/25
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/27
- [Emacs-diffs] Changes to emacs/lisp/calendar/cal-menu.el,v, Glenn Morris, 2008/03/31