From 592b74b4e5a55e3c5ff96ac7e03d8f12742123f2 Mon Sep 17 00:00:00 2001 From: "mostafah%oeone.com" Date: Fri, 28 Nov 2003 22:14:58 +0000 Subject: [PATCH] Checked in patch for bug 215259: Calendar color reset to default when edit window is opened. --- calendar/resources/content/calendarManager.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/calendar/resources/content/calendarManager.js b/calendar/resources/content/calendarManager.js index 38d1ad58aec..562235b00fd 100644 --- a/calendar/resources/content/calendarManager.js +++ b/calendar/resources/content/calendarManager.js @@ -21,6 +21,7 @@ * Contributor(s): Mike Potter * Eric Belhaire * Matthew Buckett + * Mike Loll * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPL"), or @@ -289,7 +290,15 @@ calendarManager.prototype.addServerDialogResponse = function calMan_addServerDia node.setAttribute("http://home.netscape.com/NC-rdf#path", CalendarObject.path); // CofC save off the color of the new calendar - node.setAttribute("http://home.netscape.com/NC-rdf#color", CalendarObject.color); + // Add the default color for when a user does not select a calendar color. + if( CalendarObject.color == '' ) + { + node.setAttribute("http://home.netscape.com/NC-rdf#color", "#F9F4FF"); + } + else + { + node.setAttribute("http://home.netscape.com/NC-rdf#color", CalendarObject.color); + } if( CalendarObject.remotePath.indexOf( "http://" ) != -1 || CalendarObject.remotePath.indexOf( "https://" ) != -1 ||