Commit 68575ab0 authored by Ulf Jasper's avatar Ulf Jasper
Browse files

icalendar: Take care of multiple vcalendars in a single file.

lisp/ChangeLog:

	* calendar/icalendar.el (icalendar--all-events): Take care of
	multiple vcalendars in a single file.
	(icalendar--convert-float-to-ical): checkdoc fixes.

	* automated/icalendar-tests.el (icalendar-tests--compare-strings):
	Removed, simply use string=.
	(icalendar--diarytime-to-isotime)
	(icalendar--datetime-to-diary-date)
	(icalendar--datestring-to-isodate)
	(icalendar--format-ical-event)
	(icalendar--parse-summary-and-rest)
	(icalendar-tests--do-test-import)
	(icalendar-tests--do-test-cycle) : Changed argument order of
	string= to EXPECTED ACTUAL.
	(icalendar--import-format-sample)
	(icalendar--format-ical-event)
	(icalendar-import-non-recurring)
	(icalendar-import-rrule)
	(icalendar-import-duration)
	(icalendar-import-bug-6766)
	(icalendar-real-world): Adjusted to string= instead of
	icalendar-tests--compare-strings.
	(icalendar-import-multiple-vcalendars): New.
parent d6f0886c
2011-07-26 Ulf Jasper <ulf.jasper@web.de>
* calendar/icalendar.el (icalendar--all-events): Take care of
multiple vcalendars in a single file.
(icalendar--convert-float-to-ical): checkdoc fixes.
2011-07-25 Deniz Dogan <deniz@dogan.se>
* image.el (insert-image): Clarifying docstring.
......
......@@ -412,10 +412,15 @@ children."
(setq result subresult)))))
result))
; private
;; private
(defun icalendar--all-events (icalendar)
"Return the list of all existing events in the given ICALENDAR."
(icalendar--get-children (car icalendar) 'VEVENT))
(let ((result '()))
(mapc (lambda (elt)
(setq result (append (icalendar--get-children elt 'VEVENT)
result)))
(nreverse icalendar))
result))
(defun icalendar--split-value (value-string)
"Split VALUE-STRING at ';='."
......@@ -1571,8 +1576,8 @@ entries. ENTRY-MAIN is the first line of the diary entry."
(n (nth 3 sexp))
(day (nth 4 sexp))
(summary
(replace-regexp-in-string
"\\(^\s+\\|\s+$\\)" ""
(replace-regexp-in-string
"\\(^\s+\\|\s+$\\)" ""
(buffer-substring (point) (point-max)))))
(when day
......@@ -1590,7 +1595,7 @@ entries. ENTRY-MAIN is the first line of the diary entry."
(null (let ((date (calendar-current-date))
(entry entry-main))
(diary-float month dayname n)))
(concat
(concat
"\nEXDATE;VALUE=DATE:"
(format-time-string "%Y%m%d" (current-time))))
"\nRRULE:"
......
2011-07-26 Ulf Jasper <ulf.jasper@web.de>
* automated/icalendar-tests.el (icalendar-tests--compare-strings):
Removed, simply use string=.
(icalendar--diarytime-to-isotime)
(icalendar--datetime-to-diary-date)
(icalendar--datestring-to-isodate)
(icalendar--format-ical-event)
(icalendar--parse-summary-and-rest)
(icalendar-tests--do-test-import)
(icalendar-tests--do-test-cycle) : Changed argument order of
string= to EXPECTED ACTUAL.
(icalendar--import-format-sample)
(icalendar--format-ical-event)
(icalendar-import-non-recurring)
(icalendar-import-rrule)
(icalendar-import-duration)
(icalendar-import-bug-6766)
(icalendar-real-world): Adjusted to string= instead of
icalendar-tests--compare-strings.
(icalendar-import-multiple-vcalendars): New.
2011-05-11 Teodor Zlatanov <tzz@lifelogs.com>
* automated/gnus-tests.el: Add wrapper for Gnus tests.
......
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment