rem: var composite = getDisplayComposite(); 
add: var composite = getCompositeCalendar(); 
context: function setCalendarManagerUI(){    var calendarList = document.getElementById("list-calendars-listbox");    var child;    while ((child = calendarList.lastChild) && (child.tagName == "listitem")) {        calendarList.removeChild(child);    }    var composite = getDisplayComposite();    var calmgr = getCalendarManager();    var calendars = calmgr.getCalendars({});    var hasRefreshableCal = false;    for each (var calendar in calendars) {        if (calendar.canRefresh) {            hasRefreshableCal = true;        }        var listItem = document.createElement("listitem");        var checkCell = document.createElement("listcell");        checkCell.setAttribute("type", "checkbox");        checkCell.setAttribute("checked",                                composite.getCalendar(calendar.uri) ? true : false);        listItem.appendChild(checkCell);        listItem.addEventListener("click", onCalendarCheckboxClick, true);        var colorCell = document.createElement("listcell");        try {           var calColor = calmgr.getCalendarPref(calendar, 'color');           colorCell.style.background = calColor;        } catch(e) {}        listItem.appendChild(colorCell);        var nameCell = document.createElement("listcell");        nameCell.setAttribute("label", calendar.name);        listItem.appendChild(nameCell);        listItem.calendar = calendar;        calendarList.appendChild(listItem);        if (calendarList.selectedIndex == -1)            calendarList.selectedIndex = 0;        }    var remoteCommand = document.getElementById("reload_remote_calendars");    if (!hasRefreshableCal) {        remoteCommand.setAttribute("disabled", true);    } else {        remoteCommand.removeAttribute("disabled");    }}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/67f9d85622b78fba73d946fd9591b42ff2498878/calendarManagement.js/clean/calendar/resources/content/calendarManagement.js