Misc improvements to sunbird views. bug 300180, patch by jminta, r=mvl
This commit is contained in:
Родитель
2f9ab3cdd3
Коммит
78312347ce
|
@ -112,19 +112,6 @@ DayView.prototype.refreshEvents = function()
|
|||
this.removeElementsByAttribute("eventbox", "dayview");
|
||||
this.eventList = new Array();
|
||||
|
||||
// set view limits for the day
|
||||
// XXX expand if event outside this window. Or better, always display the
|
||||
// complete day, but stroll as needed
|
||||
var sHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultstarthour", 8);
|
||||
var eHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultendhour", 17);
|
||||
var i;
|
||||
for (i = 0; i < 24; i++) {
|
||||
if ((i < sHour) || (i > eHour))
|
||||
document.getElementById("day-tree-item-"+i).setAttribute("hidden", "true");
|
||||
else
|
||||
document.getElementById("day-tree-item-"+i).removeAttribute("hidden");
|
||||
}
|
||||
|
||||
// Figure out the start and end days for the week we're currently viewing
|
||||
var selectedDateTime = this.calendarWindow.getSelectedDate();
|
||||
this.displayStartDate = new Date(selectedDateTime.getFullYear(),
|
||||
|
@ -364,12 +351,43 @@ DayView.prototype.createAllDayEventBox = function dayview_createAllDayEventBox(
|
|||
}
|
||||
|
||||
DayView.prototype.addToDisplayList = function(itemOccurrence, startDate, endDate)
|
||||
{
|
||||
this.eventList.push({event:itemOccurrence, start:startDate, end:endDate});
|
||||
{
|
||||
//HACK because startDate is convert to the proper TZ, but
|
||||
//startDate.jsDate is not
|
||||
var adjustedStartDate = new Date();
|
||||
var adjustedEndDate = new Date();
|
||||
adjustedStartDate.setFullYear(startDate.year);
|
||||
adjustedStartDate.setMonth(startDate.month);
|
||||
adjustedStartDate.setDate(startDate.day);
|
||||
adjustedEndDate.setFullYear(endDate.year);
|
||||
adjustedEndDate.setMonth(endDate.month);
|
||||
adjustedEndDate.setDate(endDate.day);
|
||||
|
||||
// Check if the event is within the bounds of events to be displayed.
|
||||
if ((adjustedEndDate < this.displayStartDate) ||
|
||||
(adjustedStartDate > this.displayEndDate))
|
||||
return;
|
||||
|
||||
this.eventList.push({event:itemOccurrence, start:startDate.clone(), end:endDate.clone()});
|
||||
}
|
||||
|
||||
DayView.prototype.drawEventBoxes = function()
|
||||
{
|
||||
var sHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultstarthour", 8);
|
||||
var eHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultendhour", 17);
|
||||
for each (event in this.eventList) {
|
||||
if(event.end.hour > eHour)
|
||||
eHour = event.end.hour;
|
||||
if(event.start.hour < sHour)
|
||||
sHour = event.start.hour;
|
||||
}
|
||||
var i;
|
||||
for (i = 0; i < 24; i++) {
|
||||
if ((i < sHour) || (i > eHour))
|
||||
document.getElementById("day-tree-item-"+i).setAttribute("hidden", "true");
|
||||
else
|
||||
document.getElementById("day-tree-item-"+i).removeAttribute("hidden");
|
||||
}
|
||||
this.setDrawProperties(this.eventList);
|
||||
var event;
|
||||
for (event in this.eventList) {
|
||||
|
@ -388,20 +406,6 @@ DayView.prototype.createEventBoxInternal = function(event)
|
|||
var endDate = event.end;
|
||||
var calEvent = itemOccurrence.QueryInterface(Components.interfaces.calIEvent);
|
||||
|
||||
// XXX Centralize this next checks
|
||||
// Check if the event is within the bounds of events to be displayed.
|
||||
if ((endDate.jsDate < this.displayStartDate) ||
|
||||
(startDate.jsDate > this.displayEndDate))
|
||||
return;
|
||||
|
||||
// XXX Should this really be done? better would be to adjust the
|
||||
// display boundaries
|
||||
if (startDate.jsDate < this.displayStartDate)
|
||||
startDate.jsDate = this.displayStartDate;
|
||||
|
||||
if (endDate.jsDate > this.displayEndDate)
|
||||
endDate.jsDate = this.displayEndDate;
|
||||
|
||||
startDate.normalize();
|
||||
endDate.normalize();
|
||||
|
||||
|
|
|
@ -158,7 +158,7 @@ function MonthView( calendarWindow )
|
|||
}
|
||||
}
|
||||
|
||||
//calendarWindow.EventSelection.addObserver( monthViewEventSelectionObserver );
|
||||
calendarWindow.EventSelection.addObserver( monthViewEventSelectionObserver );
|
||||
|
||||
this.showingLastDay = false;
|
||||
|
||||
|
@ -249,21 +249,102 @@ MonthView.prototype.refreshEvents = function()
|
|||
0, jsDateToDateTime(startDate), jsDateToDateTime(endDate), getListener);
|
||||
}
|
||||
|
||||
MonthView.prototype.createEventDotInternal = function(itemOccurrence, startDate, endDate)
|
||||
{
|
||||
//This is a HACK because startDate and indexOfDate don't get along well
|
||||
//in terms of timezones.
|
||||
var adjustedDate = new Date();
|
||||
adjustedDate.setFullYear(startDate.year);
|
||||
adjustedDate.setMonth(startDate.month);
|
||||
adjustedDate.setDate(startDate.day);
|
||||
dayBoxItem = this.dayBoxItemArray[this.indexOfDate(adjustedDate)];
|
||||
|
||||
var dotBoxHolder
|
||||
if( !document.getElementById( "dotboxholder"+startDate.month+'-'+startDate.day ) ) {
|
||||
dotBoxHolder = document.createElement( "hbox" );
|
||||
dotBoxHolder.setAttribute( "id", "dotboxholder"+startDate.month+'-'+startDate.day );
|
||||
dotBoxHolder.setAttribute( "eventbox", "monthview" );
|
||||
dayBoxItem.appendChild( dotBoxHolder );
|
||||
}
|
||||
else {
|
||||
dotBoxHolder = document.getElementById( "dotboxholder"+startDate.month+'-'+startDate.day );
|
||||
}
|
||||
|
||||
if( dotBoxHolder.childNodes.length >= kMAX_NUMBER_OF_DOTS_IN_MONTH_VIEW )
|
||||
return;
|
||||
|
||||
var calEvent = itemOccurrence.QueryInterface(Components.interfaces.calIEvent);
|
||||
|
||||
var eventDotBox = document.createElement( "box" );
|
||||
eventDotBox.setAttribute( "eventbox", "monthview" );
|
||||
eventDot = document.createElement( "image" );
|
||||
eventDot.setAttribute( "class", "month-view-event-dot-class" );
|
||||
eventDot.setAttribute("id", "month-view-event-box-" + itemOccurrence.id );
|
||||
eventDot.setAttribute("name", "month-view-event-box-" + itemOccurrence.id );
|
||||
|
||||
eventDot.setAttribute("onclick", "monthEventBoxClickEvent( this, event )" );
|
||||
eventDot.setAttribute("ondblclick", "monthEventBoxDoubleClickEvent( this, event )" );
|
||||
eventDot.setAttribute("onmouseover", "onMouseOverGridOccurrence(event)" );
|
||||
eventDot.setAttribute("tooltip", "gridOccurrenceTooltip" );
|
||||
eventDot.setAttribute("ondraggesture", "nsDragAndDrop.startDrag(event,monthViewEventDragAndDropObserver);" );
|
||||
eventDot.occurrence = itemOccurrence; // for mouseover preview
|
||||
eventDot.event = calEvent;
|
||||
eventDotBox.appendChild( eventDot );
|
||||
dotBoxHolder.appendChild( eventDotBox );
|
||||
}
|
||||
|
||||
MonthView.prototype.maxEventsToShow = function( dayBox ) {
|
||||
//create a dummy eventBox to get its height
|
||||
eventBox = document.createElement("box");
|
||||
eventBox.setAttribute("id", "month-view-event-box-dummy" );
|
||||
eventBox.setAttribute("class", "month-view-event-class default");
|
||||
eventBox.setAttribute("eventbox", "monthview" );
|
||||
|
||||
// Make a text item to show the event title
|
||||
var eventBoxText = document.createElement("label");
|
||||
eventBoxText.setAttribute("crop", "end");
|
||||
eventBoxText.setAttribute("class", "month-day-event-text-class");
|
||||
|
||||
var eventStartTime = new Date(new Date().getTime());
|
||||
var StartFormattedTime = this.calendarWindow.dateFormater.getFormatedTime(eventStartTime);
|
||||
eventBoxText.setAttribute("value", StartFormattedTime+' '+ "Dummy");
|
||||
eventBoxText.setAttribute("flex", "1");
|
||||
eventBox.appendChild(eventBoxText);
|
||||
dayBoxItem.appendChild(eventBox);
|
||||
|
||||
//Subtract the height of the number label
|
||||
var offsetY = dayBoxItem.firstChild.boxObject.height;
|
||||
var useableSpace = dayBoxItem.boxObject.height - offsetY;
|
||||
var maxEvents = useableSpace/eventBox.boxObject.height;
|
||||
dayBoxItem.removeChild(eventBox);
|
||||
return maxEvents;
|
||||
}
|
||||
|
||||
MonthView.prototype.createEventBoxInternal = function(itemOccurrence, startDate, endDate)
|
||||
{
|
||||
dayBoxItem = this.dayBoxItemArray[this.indexOfDate(startDate.jsDate)];
|
||||
//This is a HACK because startDate and indexOfDate don't get along well
|
||||
//in terms of timezones.
|
||||
var adjustedDate = new Date();
|
||||
adjustedDate.setFullYear(startDate.year);
|
||||
adjustedDate.setMonth(startDate.month);
|
||||
adjustedDate.setDate(startDate.day);
|
||||
dayBoxItem = this.dayBoxItemArray[this.indexOfDate(adjustedDate)];
|
||||
if (!dayBoxItem)
|
||||
return;
|
||||
|
||||
var calEvent = itemOccurrence.QueryInterface(Components.interfaces.calIEvent);
|
||||
|
||||
|
||||
if(dayBoxItem.childNodes.length >= this.maxEventsToShow( dayBoxItem ) ) {
|
||||
this.createEventDotInternal(itemOccurrence, startDate, endDate);
|
||||
return;
|
||||
}
|
||||
|
||||
// Make a box item to hold the event
|
||||
eventBox = document.createElement("box");
|
||||
eventBox.setAttribute("id", "month-view-event-box-" + itemOccurrence.id );
|
||||
eventBox.setAttribute("name", "month-view-event-box-" + itemOccurrence.id );
|
||||
//eventBox.setAttribute( "event"+toString(calendarEventDisplay.event.id), true );
|
||||
|
||||
this.setEventboxClass(eventBox, calEvent, "month-view");
|
||||
eventBox.setAttribute("class", "month-view-event-class default");
|
||||
|
||||
eventBox.setAttribute("eventbox", "monthview" );
|
||||
|
@ -282,6 +363,7 @@ MonthView.prototype.createEventBoxInternal = function(itemOccurrence, startDate,
|
|||
var eventBoxText = document.createElement("label");
|
||||
eventBoxText.setAttribute("crop", "end");
|
||||
eventBoxText.setAttribute("class", "month-day-event-text-class");
|
||||
this.setEventboxClass(eventBox, calEvent, "month-view");
|
||||
|
||||
if (calEvent.startDate.isDate) {
|
||||
eventBox.setAttribute("allday", "true");
|
||||
|
@ -297,6 +379,8 @@ MonthView.prototype.createEventBoxInternal = function(itemOccurrence, startDate,
|
|||
// 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");
|
||||
eventBoxText.setAttribute("ondraggesture", "nsDragAndDrop.startDrag(event,monthViewEventDragAndDropObserver);");
|
||||
|
@ -305,7 +389,6 @@ MonthView.prototype.createEventBoxInternal = function(itemOccurrence, startDate,
|
|||
|
||||
eventBox.appendChild(eventBoxText);
|
||||
|
||||
// XXX need to look at the number of children here and determine what we're supposed to do
|
||||
dayBoxItem.appendChild(eventBox);
|
||||
|
||||
/*
|
||||
|
|
|
@ -262,17 +262,100 @@ MultiweekView.prototype.refreshEvents = function multiweekView_refreshEvents( )
|
|||
0, jsDateToDateTime(startDate), jsDateToDateTime(endDate),
|
||||
getListener);
|
||||
|
||||
}
|
||||
|
||||
MultiweekView.prototype.createEventDotInternal = function(itemOccurrence, startDate, endDate)
|
||||
{
|
||||
//This is a HACK because startDate and indexOfDate don't get along well
|
||||
//in terms of timezones.
|
||||
var adjustedDate = new Date();
|
||||
adjustedDate.setFullYear(startDate.year);
|
||||
adjustedDate.setMonth(startDate.month);
|
||||
adjustedDate.setDate(startDate.day);
|
||||
dayBoxItem = this.dayBoxItemArray[this.indexOfDate(adjustedDate)];
|
||||
|
||||
var dotBoxHolder
|
||||
if( !document.getElementById( "dotboxholder"+startDate.month+'-'+startDate.day ) ) {
|
||||
dotBoxHolder = document.createElement( "box" );
|
||||
dotBoxHolder.setAttribute( "id", "dotboxholder"+startDate.month+'-'+startDate.day );
|
||||
dotBoxHolder.setAttribute( "eventbox", "multiweekview" );
|
||||
dayBoxItem.appendChild( dotBoxHolder );
|
||||
}
|
||||
else {
|
||||
dotBoxHolder = document.getElementById( "dotboxholder"+startDate.month+'-'+startDate.day );
|
||||
}
|
||||
|
||||
if( dotBoxHolder.childNodes.length >= kMAX_NUMBER_OF_DOTS_IN_MONTH_VIEW )
|
||||
return;
|
||||
|
||||
var calEvent = itemOccurrence.QueryInterface(Components.interfaces.calIEvent);
|
||||
|
||||
var eventDotBox = document.createElement( "box" );
|
||||
eventDotBox.setAttribute( "eventbox", "multiweekview" );
|
||||
eventDot = document.createElement( "image" );
|
||||
eventDot.setAttribute( "class", "multiweek-view-event-dot-class" );
|
||||
eventDot.setAttribute("id", "multiweek-view-event-box-" + itemOccurrence.id );
|
||||
eventDot.setAttribute("name", "multiweek-view-event-box-" + itemOccurrence.id );
|
||||
|
||||
eventDot.setAttribute("onclick", "monthEventBoxClickEvent( this, event )" );
|
||||
eventDot.setAttribute("ondblclick", "monthEventBoxDoubleClickEvent( this, event )" );
|
||||
eventDot.setAttribute("onmouseover", "onMouseOverGridOccurrence(event)" );
|
||||
eventDot.setAttribute("tooltip", "gridOccurrenceTooltip" );
|
||||
eventDot.setAttribute("ondraggesture", "nsDragAndDrop.startDrag(event,monthViewEventDragAndDropObserver);" );
|
||||
eventDot.occurrence = itemOccurrence; // for mouseover preview
|
||||
eventDot.event = calEvent;
|
||||
eventDotBox.appendChild( eventDot );
|
||||
dotBoxHolder.appendChild( eventDotBox );
|
||||
|
||||
}
|
||||
|
||||
MultiweekView.prototype.maxEventsToShow = function( dayBox ) {
|
||||
//create a dummy eventBox to get its height
|
||||
eventBox = document.createElement("box");
|
||||
eventBox.setAttribute("id", "multiweek-view-event-box-dummy" );
|
||||
eventBox.setAttribute("class", "multiweek-view-event-class default");
|
||||
eventBox.setAttribute("eventbox", "multiweekview" );
|
||||
|
||||
// Make a text item to show the event title
|
||||
var eventBoxText = document.createElement("label");
|
||||
eventBoxText.setAttribute("crop", "end");
|
||||
eventBoxText.setAttribute("class", "multiweek-day-event-text-class");
|
||||
|
||||
var eventStartTime = new Date(new Date().getTime());
|
||||
var StartFormattedTime = this.calendarWindow.dateFormater.getFormatedTime(eventStartTime);
|
||||
eventBoxText.setAttribute("value", StartFormattedTime+' '+ "Dummy");
|
||||
eventBoxText.setAttribute("flex", "1");
|
||||
eventBox.appendChild(eventBoxText);
|
||||
dayBoxItem.appendChild(eventBox);
|
||||
|
||||
//Subtract the height of the number label
|
||||
var offsetY = dayBoxItem.firstChild.boxObject.height;
|
||||
var useableSpace = dayBoxItem.boxObject.height - offsetY;
|
||||
var maxEvents = useableSpace/eventBox.boxObject.height;
|
||||
dayBoxItem.removeChild(eventBox);
|
||||
return maxEvents;
|
||||
}
|
||||
// JT: Liberal code reuse (ie. Cut and Paste)
|
||||
// Create an eventbox. Expects an ItemOccurence
|
||||
MultiweekView.prototype.createEventBoxInternal = function multiweekView_createEventBox(itemOccurrence, startDate, endDate)
|
||||
{
|
||||
var DisplayDate = new Date(startDate.jsDate);
|
||||
//This is a HACK because startDate and indexOfDate don't get along well
|
||||
//in terms of timezones.
|
||||
var adjustedDate = new Date();
|
||||
adjustedDate.setFullYear(startDate.year);
|
||||
adjustedDate.setMonth(startDate.month);
|
||||
adjustedDate.setDate(startDate.day);
|
||||
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" );
|
||||
|
@ -294,6 +377,7 @@ MultiweekView.prototype.createEventBoxInternal = function multiweekView_createEv
|
|||
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)
|
||||
{
|
||||
|
@ -311,6 +395,8 @@ MultiweekView.prototype.createEventBoxInternal = function multiweekView_createEv
|
|||
// 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" );
|
||||
|
||||
|
|
|
@ -115,21 +115,6 @@ function WeekView( calendarWindow )
|
|||
*/
|
||||
WeekView.prototype.refreshEvents = function()
|
||||
{
|
||||
//initialize view limits from prefs
|
||||
this.lowestStartHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultstarthour", 8);
|
||||
this.highestEndHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultendhour", 17);
|
||||
|
||||
//now hide those that aren't applicable
|
||||
for (var i = 0; i < 24; i++) {
|
||||
document.getElementById("week-view-row-"+i).removeAttribute("collapsed");
|
||||
}
|
||||
for (i = 0; i < this.lowestStartHour; i++) {
|
||||
document.getElementById("week-view-row-"+i).setAttribute("collapsed", "true");
|
||||
}
|
||||
for (i = (this.highestEndHour + 1); i < 24; i++) {
|
||||
document.getElementById("week-view-row-"+i ).setAttribute("collapsed", "true");
|
||||
}
|
||||
|
||||
// clean up anything that was here before
|
||||
this.removeElementsByAttribute("eventbox", "weekview");
|
||||
this.eventList = new Array();
|
||||
|
@ -329,11 +314,32 @@ WeekView.prototype.refreshEvents = function()
|
|||
|
||||
WeekView.prototype.addToDisplayList = function(itemOccurrence, startDate, endDate)
|
||||
{
|
||||
this.eventList.push({event:itemOccurrence, start:startDate, end:endDate});
|
||||
this.eventList.push({event:itemOccurrence, start:startDate.clone(), end:endDate.clone()});
|
||||
}
|
||||
|
||||
WeekView.prototype.drawEventBoxes = function()
|
||||
{
|
||||
//initialize view limits from prefs
|
||||
this.lowestStartHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultstarthour", 8);
|
||||
this.highestEndHour = getIntPref(this.calendarWindow.calendarPreferences.calendarPref, "event.defaultendhour", 17);
|
||||
for each (event in this.eventList) {
|
||||
if(event.end.hour > this.highestEndHour)
|
||||
this.highestEndHour = event.end.hour;
|
||||
if(event.start.hour < this.lowestStartHour)
|
||||
this.lowestStartHour = event.start.hour;
|
||||
}
|
||||
|
||||
//now hide those that aren't applicable
|
||||
for (var i = 0; i < 24; i++) {
|
||||
document.getElementById("week-view-row-"+i).removeAttribute("collapsed");
|
||||
}
|
||||
for (i = 0; i < this.lowestStartHour; i++) {
|
||||
document.getElementById("week-view-row-"+i).setAttribute("collapsed", "true");
|
||||
}
|
||||
for (i = (this.highestEndHour + 1); i < 24; i++) {
|
||||
document.getElementById("week-view-row-"+i ).setAttribute("collapsed", "true");
|
||||
}
|
||||
|
||||
// Need to split in seperate lists for each day.
|
||||
var lists = new Array();
|
||||
for (var i=0; i<7; ++i) {
|
||||
|
@ -365,25 +371,21 @@ WeekView.prototype.createEventBoxInternal = function (event)
|
|||
var endDate = event.end;
|
||||
var calEvent = itemOccurrence.QueryInterface(Components.interfaces.calIEvent);
|
||||
|
||||
// Check if the event is within the bounds of events to be displayed.
|
||||
if ((endDate.jsDate < this.displayStartDate) ||
|
||||
(startDate.jsDate > this.displayEndDate))
|
||||
return;
|
||||
//HACK because event.start is convert to the proper TZ, but
|
||||
//event.start.jsDate is not!
|
||||
var adjustedStartDate = new Date();
|
||||
var adjustedEndDate = new Date();
|
||||
adjustedStartDate.setFullYear(startDate.year);
|
||||
adjustedStartDate.setMonth(startDate.month);
|
||||
adjustedStartDate.setDate(startDate.day);
|
||||
adjustedEndDate.setFullYear(endDate.year);
|
||||
adjustedEndDate.setMonth(endDate.month);
|
||||
adjustedEndDate.setDate(endDate.day);
|
||||
|
||||
// XXX Should this really be done? better would be to adjust the
|
||||
// lowestStart and highestEnd
|
||||
if ((endDate.hour < this.lowestStartHour) ||
|
||||
(startDate.hour > this.highestEndHour))
|
||||
// Check if the event is within the bounds of events to be displayed.
|
||||
if ((adjustedEndDate < this.displayStartDate) ||
|
||||
(adjustedStartDate > this.displayEndDate))
|
||||
return;
|
||||
|
||||
if (startDate.hour < this.lowestStartHour) {
|
||||
startDate.hour = this.lowestStartHour;
|
||||
startDate.normalize();
|
||||
}
|
||||
if (endDate.hour > this.highestEndHour) {
|
||||
endDate.hour = this.highestEndHour;
|
||||
endDate.normalize();
|
||||
}
|
||||
|
||||
/*
|
||||
if (calEvent.isAllDay) {
|
||||
|
@ -476,6 +478,8 @@ WeekView.prototype.createEventBoxInternal = function (event)
|
|||
descriptionElement.appendChild(document.createTextNode(descriptionText));
|
||||
eventBox.appendChild( descriptionElement );
|
||||
}
|
||||
if(this.calendarWindow.EventSelection.isSelectedEvent(calEvent))
|
||||
eventBox.setAttribute( "eventselected", "true" );
|
||||
|
||||
debug("Adding eventBox " + eventBox + "\n");
|
||||
if (!startDate.isDate) {
|
||||
|
|
|
@ -471,9 +471,10 @@
|
|||
|
||||
.multiweek-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.multiweek-view-event-dot-class
|
||||
|
@ -718,9 +719,10 @@
|
|||
|
||||
.month-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.all-day-event-class,
|
||||
|
@ -942,7 +944,7 @@
|
|||
|
||||
.day-view-all-day-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* !important to prevent calendar-specific color setting from overriding this */
|
||||
background-color : #D5E3F2 !important;
|
||||
color : #000000 !important;
|
||||
|
@ -977,7 +979,7 @@
|
|||
|
||||
.day-view-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* set padding to prevent jittering when border width is changed */
|
||||
padding-left : 0px;
|
||||
padding-right : 0px;
|
||||
|
@ -1253,8 +1255,9 @@ then observed (ERic 20/06/03)
|
|||
|
||||
.week-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
|
|
|
@ -478,9 +478,10 @@
|
|||
|
||||
.multiweek-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.multiweek-view-event-dot-class
|
||||
|
@ -725,9 +726,10 @@
|
|||
|
||||
.month-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.all-day-event-class,
|
||||
|
@ -949,7 +951,7 @@
|
|||
|
||||
.day-view-all-day-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* !important to prevent calendar-specific color setting from overriding this */
|
||||
background-color : #D5E3F2 !important;
|
||||
color : #000000 !important;
|
||||
|
@ -984,7 +986,7 @@
|
|||
|
||||
.day-view-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* set padding to prevent jittering when border width is changed */
|
||||
padding-left : 0px;
|
||||
padding-right : 0px;
|
||||
|
@ -1261,8 +1263,9 @@ then observed (ERic 20/06/03)
|
|||
|
||||
.week-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
|
|
|
@ -202,9 +202,10 @@
|
|||
|
||||
.multiweek-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.multiweek-view-event-dot-class
|
||||
|
@ -446,9 +447,10 @@
|
|||
|
||||
.month-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.all-day-event-class,
|
||||
|
@ -660,9 +662,10 @@
|
|||
|
||||
.day-view-all-day-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* !important to prevent calendar-specific color setting from overriding this */
|
||||
background-color : #D5E3F2 !important;
|
||||
color : #000000 !important;
|
||||
/* set margins to prevent jittering when border width is changed */
|
||||
margin-top : -1px;
|
||||
margin-left : -1px;
|
||||
|
@ -694,13 +697,14 @@
|
|||
|
||||
.day-view-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* set padding to prevent jittering when border width is changed */
|
||||
padding-left : 0px;
|
||||
padding-right : 0px;
|
||||
padding-top : 0px;
|
||||
/* !important to prevent calendar-specific color setting from overriding this */
|
||||
background-color : #D5E3F2 !important;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
|
@ -966,8 +970,9 @@ then observed (ERic 20/06/03)
|
|||
|
||||
.week-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
|
|
|
@ -202,9 +202,10 @@
|
|||
|
||||
.multiweek-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.multiweek-view-event-dot-class
|
||||
|
@ -446,9 +447,10 @@
|
|||
|
||||
.month-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
margin : 0px;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
.all-day-event-class,
|
||||
|
@ -664,9 +666,10 @@
|
|||
|
||||
.day-view-all-day-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* !important to prevent calendar-specific color setting from overriding this */
|
||||
background-color : #D5E3F2 !important;
|
||||
color : #000000 !important;
|
||||
/* set margins to prevent jittering when border width is changed */
|
||||
margin-top : -1px;
|
||||
margin-left : -1px;
|
||||
|
@ -698,13 +701,14 @@
|
|||
|
||||
.day-view-event-class[eventselected="true"]
|
||||
{
|
||||
border : 2px solid #990000;
|
||||
border : 2px solid #990000 !important;
|
||||
/* set padding to prevent jittering when border width is changed */
|
||||
padding-left : 0px;
|
||||
padding-right : 0px;
|
||||
padding-top : 0px;
|
||||
/* !important to prevent calendar-specific color setting from overriding this */
|
||||
background-color : #D5E3F2 !important;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
|
@ -970,8 +974,9 @@ then observed (ERic 20/06/03)
|
|||
|
||||
.week-view-event-class[eventselected="true"]
|
||||
{
|
||||
background-color : #D5E3F2;
|
||||
border : 2px solid #990000;
|
||||
background-color : #D5E3F2 !important;
|
||||
border : 2px solid #990000 !important;
|
||||
color : #000000 !important;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
|
|
Загрузка…
Ссылка в новой задаче