diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 01e34af869b0c15275738f4977beaadbc1a6085a..f352cf968f64abad1df5f3ee5070c30fa78b2efa 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,14 +1,3 @@ -2013-12-19 Jan Tatarik - - * gnus-icalendar.el (gnus-icalendar--update-org-event) - (gnus-icalendar-event->org-entry) - (gnus-icalendar--update-org-event) - (gnus-icalendar:org-event-save) - (gnus-icalendar-event:sync-to-org, gnus-icalendar-reply) - (gnus-icalendar-sync-event-to-org, gnus-icalendar-mm-inline): - Include org link to the original message when syncing events to - org. - 2013-12-19 Katsumi Yamaoka * gnus-uu.el (gnus-uu-decode-binhex, gnus-uu-decode-binhex-view): diff --git a/lisp/gnus-icalendar.el b/lisp/gnus-icalendar.el index 23eaca1e4ce9f14ad3ab21d04e816d8b2e2bf4bd..1abcb6e27e4b40f504de1544f8ff2b1320648e82 100644 --- a/lisp/gnus-icalendar.el +++ b/lisp/gnus-icalendar.el @@ -441,7 +441,7 @@ Return nil for non-recurring EVENT." (mapconcat #'identity participants ", ")) ;; TODO: make the template customizable -(defmethod gnus-icalendar-event->org-entry ((event gnus-icalendar-event) reply-status message-link) +(defmethod gnus-icalendar-event->org-entry ((event gnus-icalendar-event) reply-status) "Return string with new `org-mode' entry describing EVENT." (with-temp-buffer (org-mode) @@ -466,10 +466,6 @@ Return nil for non-recurring EVENT." (org-entry-put (point) (car prop) (cdr prop))) props)) - (insert " ") - (org-insert-link nil message-link "Show the original message") - (insert "\n\n") - (when description (save-restriction (narrow-to-region (point) (point)) @@ -515,7 +511,7 @@ is searched." (org-show-entry)))) -(defun gnus-icalendar--update-org-event (event reply-status message-link &optional org-file) +(defun gnus-icalendar--update-org-event (event reply-status &optional org-file) (let ((file (gnus-icalendar-find-org-event-file event org-file))) (when file (with-current-buffer (find-file-noselect file) @@ -550,12 +546,6 @@ is searched." (forward-line) (delete-region (point) entry-end)) - (insert "\n") - (org-insert-link nil message-link "Show the original message") - (indent-region (line-beginning-position) (line-end-position) - (1+ entry-outline-level)) - (insert "\n") - ;; put new event description in the entry body (when description (save-restriction @@ -618,9 +608,9 @@ is searched." ;; org-capture-templates-contexts)) )) -(defun gnus-icalendar:org-event-save (event reply-status message-link) +(defun gnus-icalendar:org-event-save (event reply-status) (with-temp-buffer - (org-capture-string (gnus-icalendar-event->org-entry event reply-status message-link) + (org-capture-string (gnus-icalendar-event->org-entry event reply-status) gnus-icalendar-org-template-key))) (defun gnus-icalendar-show-org-agenda (event) @@ -632,12 +622,12 @@ is searched." (org-agenda-list nil (gnus-icalendar-event:start event) duration-days))) -(defmethod gnus-icalendar-event:sync-to-org ((event gnus-icalendar-event-request) reply-status message-link) +(defmethod gnus-icalendar-event:sync-to-org ((event gnus-icalendar-event-request) reply-status) (if (gnus-icalendar-find-org-event-file event) - (gnus-icalendar--update-org-event event reply-status message-link) - (gnus-icalendar:org-event-save event reply-status message-link))) + (gnus-icalendar--update-org-event event reply-status) + (gnus-icalendar:org-event-save event reply-status))) -(defmethod gnus-icalendar-event:sync-to-org ((event gnus-icalendar-event-cancel) reply-status message-link) +(defmethod gnus-icalendar-event:sync-to-org ((event gnus-icalendar-event-cancel) reply-status) (when (gnus-icalendar-find-org-event-file event) (gnus-icalendar--cancel-org-event event))) @@ -687,9 +677,6 @@ only makes sense to define names or email addresses." (make-variable-buffer-local (defvar gnus-icalendar-handle nil)) -(make-variable-buffer-local - (defvar gnus-icalendar-message-link nil)) - (defun gnus-icalendar-identities () "Return list of regexp-quoted names and email addresses belonging to the user. @@ -802,13 +789,13 @@ These will be used to retrieve the RSVP information from ical events." ;; Back in article buffer (setq-local gnus-icalendar-reply-status status) (when gnus-icalendar-org-enabled-p - (gnus-icalendar--update-org-event event status gnus-icalendar-message-link) + (gnus-icalendar--update-org-event event status) ;; refresh article buffer to update the reply status (with-current-buffer gnus-summary-buffer (gnus-summary-show-article)))))))) (defun gnus-icalendar-sync-event-to-org (event) - (gnus-icalendar-event:sync-to-org event gnus-icalendar-reply-status gnus-icalendar-message-link)) + (gnus-icalendar-event:sync-to-org event gnus-icalendar-reply-status)) (defmethod gnus-icalendar-event:inline-reply-buttons ((event gnus-icalendar-event) handle) (when (gnus-icalendar-event:rsvp event) @@ -857,7 +844,6 @@ These will be used to retrieve the RSVP information from ical events." (let ((event (gnus-icalendar-event-from-handle handle (gnus-icalendar-identities)))) (setq gnus-icalendar-reply-status nil) - (setq-local gnus-icalendar-message-link (org-gnus-store-link)) (when event (gmm-labels ((insert-button-group (buttons)