[CalendarServer-changes] [11624] PyCalendar/branches/json-2/src/pycalendar
source_changes at macosforge.org
source_changes at macosforge.org
Wed Aug 21 08:35:00 PDT 2013
Revision: 11624
http://trac.calendarserver.org//changeset/11624
Author: cdaboo at apple.com
Date: 2013-08-21 08:35:00 -0700 (Wed, 21 Aug 2013)
Log Message:
-----------
Fixes following re-organization.
Modified Paths:
--------------
PyCalendar/branches/json-2/src/pycalendar/icalendar/calendar.py
PyCalendar/branches/json-2/src/pycalendar/icalendar/property.py
PyCalendar/branches/json-2/src/pycalendar/icalendar/tests/test_property.py
PyCalendar/branches/json-2/src/pycalendar/property.py
PyCalendar/branches/json-2/src/pycalendar/utcoffsetvalue.py
PyCalendar/branches/json-2/src/pycalendar/vcard/property.py
Modified: PyCalendar/branches/json-2/src/pycalendar/icalendar/calendar.py
===================================================================
--- PyCalendar/branches/json-2/src/pycalendar/icalendar/calendar.py 2013-08-20 23:19:14 UTC (rev 11623)
+++ PyCalendar/branches/json-2/src/pycalendar/icalendar/calendar.py 2013-08-21 15:35:00 UTC (rev 11624)
@@ -62,7 +62,7 @@
propertyValueChecks = ICALENDAR_VALUE_CHECKS
def __init__(self, parent=None, add_defaults=True):
- super(Calendar, self).__init__(None)
+ super(Calendar, self).__init__(add_defaults=add_defaults)
self.mName = ""
self.mDescription = ""
Modified: PyCalendar/branches/json-2/src/pycalendar/icalendar/property.py
===================================================================
--- PyCalendar/branches/json-2/src/pycalendar/icalendar/property.py 2013-08-20 23:19:14 UTC (rev 11623)
+++ PyCalendar/branches/json-2/src/pycalendar/icalendar/property.py 2013-08-21 15:35:00 UTC (rev 11624)
@@ -171,12 +171,6 @@
sValue = definitions.cICalParameter_VALUE
sText = definitions.cICalValue_TEXT
- @classmethod
- def registerDefaultValue(cls, propname, valuetype):
- if propname not in cls.sDefaultValueTypeMap:
- cls.sDefaultValueTypeMap[propname] = valuetype
-
-
def __init__(self, name=None, value=None, valuetype=None):
self.mName = name if name is not None else ""
Modified: PyCalendar/branches/json-2/src/pycalendar/icalendar/tests/test_property.py
===================================================================
--- PyCalendar/branches/json-2/src/pycalendar/icalendar/tests/test_property.py 2013-08-20 23:19:14 UTC (rev 11623)
+++ PyCalendar/branches/json-2/src/pycalendar/icalendar/tests/test_property.py 2013-08-21 15:35:00 UTC (rev 11624)
@@ -43,6 +43,7 @@
"GEO:-2.1;3.2",
"URI:http://www.example.com",
"TZOFFSETFROM:-0500",
+ "TZOFFSETFROM:-045857",
"X-FOO;VALUE=FLOAT:-1.23",
"X-Test:Some\, text.",
"X-Test:Some:, text.",
Modified: PyCalendar/branches/json-2/src/pycalendar/property.py
===================================================================
--- PyCalendar/branches/json-2/src/pycalendar/property.py 2013-08-20 23:19:14 UTC (rev 11623)
+++ PyCalendar/branches/json-2/src/pycalendar/property.py 2013-08-21 15:35:00 UTC (rev 11624)
@@ -49,6 +49,12 @@
sValue = None
sText = None
+ @classmethod
+ def registerDefaultValue(cls, propname, valuetype):
+ if propname not in cls.sDefaultValueTypeMap:
+ cls.sDefaultValueTypeMap[propname] = valuetype
+
+
def __init__(self, name=None, value=None, valuetype=None):
raise NotImplementedError
Modified: PyCalendar/branches/json-2/src/pycalendar/utcoffsetvalue.py
===================================================================
--- PyCalendar/branches/json-2/src/pycalendar/utcoffsetvalue.py 2013-08-20 23:19:14 UTC (rev 11623)
+++ PyCalendar/branches/json-2/src/pycalendar/utcoffsetvalue.py 2013-08-21 15:35:00 UTC (rev 11624)
@@ -82,7 +82,7 @@
s = ("%s%02d:%02d" if fullISO else "%s%02d%02d") % (sign, hours, mins,)
if (secs != 0):
- s = ("%s:%s" if fullISO else "%s%s") % (secs,)
+ s = ("%s:%02d" if fullISO else "%s%02d") % (s, secs,)
os.write(s)
except:
Modified: PyCalendar/branches/json-2/src/pycalendar/vcard/property.py
===================================================================
--- PyCalendar/branches/json-2/src/pycalendar/vcard/property.py 2013-08-20 23:19:14 UTC (rev 11623)
+++ PyCalendar/branches/json-2/src/pycalendar/vcard/property.py 2013-08-21 15:35:00 UTC (rev 11624)
@@ -139,12 +139,6 @@
sValue = definitions.Parameter_VALUE
sText = definitions.Value_TEXT
- @classmethod
- def registerDefaultValue(cls, propname, valuetype):
- if propname not in cls.sDefaultValueTypeMap:
- cls.sDefaultValueTypeMap[propname] = valuetype
-
-
def __init__(self, group=None, name=None, value=None, valuetype=None):
self.mGroup = group
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20130821/9b3266e6/attachment.html>
More information about the calendarserver-changes
mailing list