diff options
| author | Glenn Morris | 2008-06-26 04:54:12 +0000 |
|---|---|---|
| committer | Glenn Morris | 2008-06-26 04:54:12 +0000 |
| commit | cb9069371df1b92649845bb1fc9e249fa6bcff8e (patch) | |
| tree | e2ecf5056cb3f834bafd40ab00785be1fec27111 | |
| parent | f2a77c3a41744e43b52f0ac7a2c9bd7f8d406ae1 (diff) | |
| download | emacs-cb9069371df1b92649845bb1fc9e249fa6bcff8e.tar.gz emacs-cb9069371df1b92649845bb1fc9e249fa6bcff8e.zip | |
(calendar-mouse-holidays): Remove function.
(cal-menu-context-mouse-menu): Use calendar-cursor-holidays.
| -rw-r--r-- | lisp/calendar/cal-menu.el | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/lisp/calendar/cal-menu.el b/lisp/calendar/cal-menu.el index 8e4dfdf2e4a..b08f9f1f488 100644 --- a/lisp/calendar/cal-menu.el +++ b/lisp/calendar/cal-menu.el | |||
| @@ -161,18 +161,6 @@ Signals an error if popups are unavailable." | |||
| 161 | (error "Popup menus are not available on this system"))) | 161 | (error "Popup menus are not available on this system"))) |
| 162 | 162 | ||
| 163 | (autoload 'calendar-check-holidays "holidays") | 163 | (autoload 'calendar-check-holidays "holidays") |
| 164 | |||
| 165 | (defun calendar-mouse-holidays (&optional event) | ||
| 166 | "Pop up menu of holidays for mouse selected date. | ||
| 167 | EVENT is the event that invoked this command." | ||
| 168 | (interactive "e") | ||
| 169 | (let* ((date (calendar-cursor-to-date nil event)) | ||
| 170 | (title (format "Holidays for %s" (calendar-date-string date))) | ||
| 171 | (selection (cal-menu-x-popup-menu event title | ||
| 172 | (or (mapcar 'list (calendar-check-holidays date)) | ||
| 173 | '("None"))))) | ||
| 174 | (and selection (call-interactively selection)))) | ||
| 175 | |||
| 176 | (autoload 'diary-list-entries "diary-lib") | 164 | (autoload 'diary-list-entries "diary-lib") |
| 177 | (defvar diary-show-holidays-flag) ; only called from calendar.el | 165 | (defvar diary-show-holidays-flag) ; only called from calendar.el |
| 178 | 166 | ||
| @@ -219,11 +207,11 @@ is non-nil." | |||
| 219 | "Pop up menu for Mouse-2 for selected date in the calendar window." | 207 | "Pop up menu for Mouse-2 for selected date in the calendar window." |
| 220 | '("cal-menu-mouse2" :filter cal-menu-set-date-title | 208 | '("cal-menu-mouse2" :filter cal-menu-set-date-title |
| 221 | "--" | 209 | "--" |
| 222 | ["Holidays" calendar-mouse-holidays] | 210 | ["Holidays" calendar-cursor-holidays] |
| 223 | ["Mark date" calendar-set-mark] | 211 | ["Mark date" calendar-set-mark] |
| 224 | ["Sunrise/sunset" calendar-sunrise-sunset] | 212 | ["Sunrise/sunset" calendar-sunrise-sunset] |
| 225 | ["Other calendars" calendar-print-other-dates] | 213 | ["Other calendars" calendar-print-other-dates] |
| 226 | ;; FIXME there is a bug with last-nonmenu-event and submenus. | 214 | ;; FIXME there is a bug (#447) with last-nonmenu-event and submenus. |
| 227 | ;; These currently don't work if called without calendar window selected. | 215 | ;; These currently don't work if called without calendar window selected. |
| 228 | ("Prepare LaTeX buffer" | 216 | ("Prepare LaTeX buffer" |
| 229 | ["Daily (1 page)" cal-tex-cursor-day] | 217 | ["Daily (1 page)" cal-tex-cursor-day] |