rem: setElementValue("item-alarm", "custom"); 
add: loadDetails(); } else { for each (elem in detailsElements) { elem.collapsed = true; } detailsButton.setAttribute("label", moreLabel); 
context: function loadDialog(item){    var kDefaultTimezone = calendarDefaultTimezone();    setElementValue("item-title",       item.title);    setElementValue("item-location",    item.getProperty("LOCATION"));    setElementValue("item-url",         item.getProperty("URL"));    setElementValue("item-description", item.getProperty("DESCRIPTION"));    /* event specific properties */    if (isEvent(item)) {        var startDate = item.startDate.getInTimezone(kDefaultTimezone);        var endDate = item.endDate.getInTimezone(kDefaultTimezone);        if (startDate.isDate) {            setElementValue("event-all-day", true, "checked");            endDate.day -= 1;            endDate.normalize();        }        setElementValue("event-starttime",   startDate.jsDate);        setElementValue("event-endtime",     endDate.jsDate);    }    /* todo specific properties */    if (isToDo(item)) {        var hasDueDate = (item.dueDate != null);        setElementValue("todo-has-duedate", hasDueDate, "checked");        if (hasDueDate)            setElementValue("todo-duedate", item.dueDate.jsDate);        setElementValue("todo-completed", item.isCompleted, "checked");    }    /* attendence */    var attendeeString = "";    for each (var attendee in item.getAttendees({})) {        if (attendeeString != "")            attendeeString += ",";        attendeeString += attendee.id.split("mailto:")[1];    }    setElementValue("item-attendees", attendeeString);    /* item default calendar */    if (item.calendar) {        var calendarList = document.getElementById("item-calendar");        var calendars = getCalendarManager().getCalendars({});        for (i in calendars) {            if (item.calendar.uri.equals(calendars[i].uri))                calendarList.selectedIndex = i;        }    } else {        // no calendar attached to item        // select first entry in calendar list as default        document.getElementById("item-calendar").selectedIndex = 0;    }    /* recurrence */    /* if the item is a proxy occurrence/instance, a few things aren't valid:     * - Setting recurrence on the item     * - changing the calendar     */    if (item.parentItem != item) {        setElementValue("item-recurrence", "true", "disabled");        setElementValue("set-recurrence", "true", "disabled");        setElementValue("item-calendar", "true", "disabled");    } else if (item.recurrenceInfo)        setElementValue("item-recurrence", "true", "checked");    /* alarms */    if (item.alarmTime) {        var alarmLength = item.getProperty("alarmLength");        if (alarmLength != null) {            setElementValue("alarm-length-field", alarmLength);            setElementValue("alarm-length-units", event.getProperty("alarmUnits"));            setElementValue("alarm-trigger-relation", item.getProperty("alarmRelated"));        }        setElementValue("item-alarm", "custom");    }}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/edb75cb3aa7fe2a0098e7d7a97a91ce5dd7f6556/calendar-event-dialog.js/clean/calendar/base/content/calendar-event-dialog.js