mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 04:45:45 +00:00
it is a todo, not an event.
This commit is contained in:
parent
12c2f4c630
commit
8a1c410a8c
@ -140,16 +140,16 @@ calTodo.prototype = {
|
||||
return icalcomp;
|
||||
},
|
||||
|
||||
set icalComponent(event) {
|
||||
set icalComponent(todo) {
|
||||
this.modify();
|
||||
if (event.componentType != "VTODO") {
|
||||
event = event.getFirstSubcomponent("VTODO");
|
||||
if (!event)
|
||||
if (todo.componentType != "VTODO") {
|
||||
todo = todo.getFirstSubcomponent("VTODO");
|
||||
if (!todo)
|
||||
throw Components.results.NS_ERROR_INVALID_ARG;
|
||||
}
|
||||
|
||||
this.setItemBaseFromICS(event);
|
||||
this.mapPropsFromICS(event, this.icsEventPropMap);
|
||||
this.setItemBaseFromICS(todo);
|
||||
this.mapPropsFromICS(todo, this.icsEventPropMap);
|
||||
this.mIsAllDay = this.mStartDate && this.mStartDate.isDate;
|
||||
|
||||
var promotedProps = {
|
||||
@ -161,7 +161,7 @@ calTodo.prototype = {
|
||||
"PERCENT-COMPLETE": true,
|
||||
__proto__: this.itemBasePromotedProps
|
||||
};
|
||||
this.importUnpromotedProperties(event, promotedProps);
|
||||
this.importUnpromotedProperties(todo, promotedProps);
|
||||
// Importing didn't really change anything
|
||||
this.mDirty = false;
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user