rem: gEvent.end.year = ThisDate.getYear()+1900; gEvent.end.month = ThisDate.getMonth(); gEvent.end.day = ThisDate.getDate(); 
add: gEndDate.setMonth( ThisDate.getMonth() ); gEndDate.setDate( ThisDate.getDate() ); gEndDate.setFullYear( ThisDate.getFullYear() ); 
context: function onDatePick( datepicker ){   var ThisDate = new Date( datepicker.value);   if( datepicker.id == "end-date-picker" )   {      gEvent.end.year = ThisDate.getYear()+1900;      gEvent.end.month = ThisDate.getMonth();      gEvent.end.day = ThisDate.getDate();            //get the new end time by adding on the time difference to the start time.      gDateDifference = gEvent.end.getTime() - gEvent.start.getTime();            updateOKButton();      return;   }   if( datepicker.id == "start-date-picker" )   {      gEvent.start.year = ThisDate.getYear()+1900;      gEvent.start.month = ThisDate.getMonth();      gEvent.start.day = ThisDate.getDate();      //get the new end time by adding on the time difference to the start time.      newEndDate = datepicker.value.getTime() + gDateDifference;               gEvent.end.setTime( newEndDate );         updateEndDateDisplay();   }   var Now = new Date();   //change the end date of recurring events to today, if the new date is after today and repeat is not checked.   if ( datepicker.value.getTime() > Now.getTime() && !getFieldValue( "repeat-checkbox", "checked" ) )    {      document.getElementById( "repeat-end-date-picker" ).value = datepicker.value;   }   updateAdvancedWeekRepeat();         updateAdvancedRepeatDayOfMonth();   updateAddExceptionButton();   updateOKButton();}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/81465269b916e59f9253fa1c7ef70fa347af6264/eventDialog.js/buggy/calendar/resources/content/eventDialog.js