diff options
| author | Glenn Morris | 2008-06-18 02:54:40 +0000 |
|---|---|---|
| committer | Glenn Morris | 2008-06-18 02:54:40 +0000 |
| commit | b40f3832e9fb52d1582dc8834184ba2ab150782c (patch) | |
| tree | afd3b0deb3bebf11f550aa5d84b11891b1ee91a4 | |
| parent | b69895cde6d3645949be969f7e8d7eaa610c7ba5 (diff) | |
| download | emacs-b40f3832e9fb52d1582dc8834184ba2ab150782c.tar.gz emacs-b40f3832e9fb52d1582dc8834184ba2ab150782c.zip | |
(cal-html-cursor-month, cal-html-cursor-year): Handle mouse events.
| -rw-r--r-- | lisp/calendar/cal-html.el | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/lisp/calendar/cal-html.el b/lisp/calendar/cal-html.el index 780da9592bf..7dbf85dae73 100644 --- a/lisp/calendar/cal-html.el +++ b/lisp/calendar/cal-html.el | |||
| @@ -408,27 +408,30 @@ four-digit YEAR. Diary entries in DIARY-LIST are included." | |||
| 408 | ;;; User commands. | 408 | ;;; User commands. |
| 409 | 409 | ||
| 410 | ;;;###cal-autoload | 410 | ;;;###cal-autoload |
| 411 | (defun cal-html-cursor-month (month year dir) | 411 | (defun cal-html-cursor-month (month year dir &optional event) |
| 412 | "Write an HTML calendar file for numeric MONTH of four-digit YEAR. | 412 | "Write an HTML calendar file for numeric MONTH of four-digit YEAR. |
| 413 | The output directory DIR is created if necessary. Interactively, | 413 | The output directory DIR is created if necessary. Interactively, |
| 414 | MONTH and YEAR are taken from the calendar cursor position. Note | 414 | MONTH and YEAR are taken from the calendar cursor position, or from |
| 415 | that any existing output files are overwritten." | 415 | the position specified by EVENT. Note that any existing output files |
| 416 | (interactive (let* ((date (calendar-cursor-to-date t)) | 416 | are overwritten." |
| 417 | (interactive (let* ((event last-nonmenu-event) | ||
| 418 | (date (calendar-cursor-to-date t event)) | ||
| 417 | (month (calendar-extract-month date)) | 419 | (month (calendar-extract-month date)) |
| 418 | (year (calendar-extract-year date))) | 420 | (year (calendar-extract-year date))) |
| 419 | (list month year (cal-html-year-dir-ask-user year)))) | 421 | (list month year (cal-html-year-dir-ask-user year) event))) |
| 420 | (make-directory dir t) | 422 | (make-directory dir t) |
| 421 | (cal-html-one-month month year dir)) | 423 | (cal-html-one-month month year dir)) |
| 422 | 424 | ||
| 423 | ;;;###cal-autoload | 425 | ;;;###cal-autoload |
| 424 | (defun cal-html-cursor-year (year dir) | 426 | (defun cal-html-cursor-year (year dir &optional event) |
| 425 | "Write HTML calendar files (index and monthly pages) for four-digit YEAR. | 427 | "Write HTML calendar files (index and monthly pages) for four-digit YEAR. |
| 426 | The output directory DIR is created if necessary. Interactively, | 428 | The output directory DIR is created if necessary. Interactively, |
| 427 | YEAR is taken from the calendar cursor position. Note that any | 429 | YEAR is taken from the calendar cursor position, or from the position |
| 428 | existing output files are overwritten." | 430 | specified by EVENT. Note that any existing output files are overwritten." |
| 429 | (interactive (let ((year (calendar-extract-year | 431 | (interactive (let* ((event last-nonmenu-event) |
| 430 | (calendar-cursor-to-date t)))) | 432 | (year (calendar-extract-year |
| 431 | (list year (cal-html-year-dir-ask-user year)))) | 433 | (calendar-cursor-to-date t event)))) |
| 434 | (list year (cal-html-year-dir-ask-user year) event))) | ||
| 432 | (make-directory dir t) | 435 | (make-directory dir t) |
| 433 | (with-temp-buffer | 436 | (with-temp-buffer |
| 434 | (cal-html-insert-year-minicals year cal-html-year-index-cols) | 437 | (cal-html-insert-year-minicals year cal-html-year-index-cols) |