rem: var adjustedDate = new Date(); adjustedDate.setDate(startDate.day); adjustedDate.setMonth(startDate.month); adjustedDate.setFullYear(startDate.year); 
add: var adjustedDate = new Date(startDate.year, startDate.month, startDate.day); 
context: MultiweekView.prototype.createEventBoxInternal = function multiweekView_createEventBox(itemOccurrence, startDate, endDate){    this.eventList.push({event:itemOccurrence, start:startDate, end:endDate});    //This is a HACK because startDate and indexOfDate don't get along well    //in terms of timezones.    var adjustedDate = new Date();    adjustedDate.setDate(startDate.day);    adjustedDate.setMonth(startDate.month);    adjustedDate.setFullYear(startDate.year);    var DisplayDate = new Date(adjustedDate);    dayBoxItem = this.dayBoxItemArray[this.indexOfDate(DisplayDate)];    // Check if the day is visible    if (!dayBoxItem)        return;    if(dayBoxItem.childNodes.length >= this.maxEventsToShow( dayBoxItem ) ) {        this.createEventDotInternal(itemOccurrence, startDate, endDate);        return;    }    var calEvent = itemOccurrence.QueryInterface(Components.interfaces.calIEvent);    // Make a box item to hold the event    eventBox = document.createElement( "box" );    eventBox.setAttribute( "id", "multiweek-view-event-box-" + itemOccurrence.id );    eventBox.setAttribute( "name", "multiweek-view-event-box-"+ itemOccurrence.id );    eventBox.setAttribute( "class", "multiweek-view-event-class default");        eventBox.setAttribute( "eventbox", "multiweekview" );    eventBox.setAttribute( "onclick", "monthEventBoxClickEvent( this, event )" );    eventBox.setAttribute( "ondblclick", "monthEventBoxDoubleClickEvent( this, event )" );    eventBox.setAttribute( "onmouseover", "onMouseOverGridOccurrence(event)" );    eventBox.setAttribute( "tooltip", "gridOccurrenceTooltip" );    eventBox.setAttribute( "ondraggesture", "nsDragAndDrop.startDrag(event,monthViewEventDragAndDropObserver);" );    eventBox.occurrence = itemOccurrence;    eventBox.event = calEvent;    var eventBoxText = document.createElement( "label" );    eventBoxText.setAttribute( "crop", "end" );    eventBoxText.setAttribute( "class", "multiweek-day-event-text-class" );    this.setEventboxClass(eventBox, calEvent, "week-view");    if(calEvent.startDate.isDate)    {        eventBox.setAttribute("allday", "true");        eventBoxText.setAttribute("value", calEvent.title );        // Create an image        var newImage = document.createElement("image");        newImage.setAttribute("class", "all-day-event-class");        eventBox.appendChild(newImage);    }    else    {        var eventStartTime = new Date(calEvent.startDate.jsDate.getTime());        var StartFormattedTime = this.calendarWindow.dateFormater.getFormatedTime(eventStartTime);        // display as "12:15 titleevent"        eventBoxText.setAttribute("value", StartFormattedTime+' '+ calEvent.title);    }    if(this.calendarWindow.EventSelection.isSelectedEvent(calEvent))         eventBox.setAttribute( "eventselected", "true" );    eventBoxText.setAttribute( "flex", "1" );    // add the text to the event box    eventBox.appendChild( eventBoxText );    dayBoxItem.appendChild(eventBox);}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/a4b6260b69694f5b24e79af2376cc1d6ba4ff46e/multiweekView.js/clean/calendar/resources/content/multiweekView.js