From 0cef8b0a0faf81eac909cc5b6fa1cd880b47caa1 Mon Sep 17 00:00:00 2001 From: "mostafah%oeone.com" Date: Thu, 28 Oct 2004 15:52:09 +0000 Subject: [PATCH] Checked in patch #162945 for bug 220075:Make task start date/due date optional (Adds IsSet to oeDateTime interface) --- calendar/libxpical/oeDateTimeImpl.cpp | 8 +++++++- calendar/libxpical/oeIICal.idl | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/calendar/libxpical/oeDateTimeImpl.cpp b/calendar/libxpical/oeDateTimeImpl.cpp index 8219699e1645..d12cba3f7dd3 100644 --- a/calendar/libxpical/oeDateTimeImpl.cpp +++ b/calendar/libxpical/oeDateTimeImpl.cpp @@ -201,7 +201,13 @@ NS_IMETHODIMP oeDateTimeImpl::SetTimeInTimezone( PRTime ms, const char *tzid ) NS_IMETHODIMP oeDateTimeImpl::Clear() { - m_datetime = icaltime_null_time(); + m_datetime = icaltime_null_time(); + return NS_OK; +} + +NS_IMETHODIMP oeDateTimeImpl::GetIsSet(PRBool *retval) +{ + *retval = ! icaltime_is_null_time(m_datetime); return NS_OK; } diff --git a/calendar/libxpical/oeIICal.idl b/calendar/libxpical/oeIICal.idl index 7165e15f4e77..ca34f9dfaac0 100644 --- a/calendar/libxpical/oeIICal.idl +++ b/calendar/libxpical/oeIICal.idl @@ -74,6 +74,7 @@ interface oeIDateTime : nsISupports attribute short minute; attribute boolean utc; readonly attribute string tzID; + readonly attribute boolean isSet; PRTime getTime(); void setTime( in PRTime ms ); void setTimeInTimezone( in PRTime ms, in string tzID );