rem: if ((itemStartTime >= startTime && itemEndTime <= endTime) || (itemStartTime <= startTime && itemEndTime > startTime) || (itemStartTime <= endTime && itemEndTime >= endTime)) { 
add: if (itemStartTime <= endTime && itemEndTime >= startTime) { 
context:     getItems: function (aItemType, aItemFilter, aCount,                        aRangeStart, aRangeEnd, aListener)    {        // we ignore aItemFilter; we always return all items.  if        // aCount != 0, we don't attempt to sort anything, and instead        // return the first aCount items that match.        var itemsFound = Array();        var startTime = 0;        // endTime needs to be the max value a PRTime can be        var endTime = 0x7fffffffffffffff;        if (aRangeStart)            startTime = aRangeStart.utcTime;        if (aRangeEnd)            endTime = aRangeEnd.utcTime;        const calIEvent = Components.interfaces.calIEvent;        const calITodo = Components.interfaces.calITodo;        for (var i = 0; i < this.mItems.length; i++) {            var item = this.mItems[i];            if (aItemType)                item = item.QueryInterface(aItemType);            if (item) {                var itemStartTime = 0;                var itemEndTime = 0;                var tmpitem = item;                if (aItemType == calIEvent ||                    (tmpitem = item.QueryInterface(calIEvent)) != null)                {                    itemStartTime = tmpitem.startDate.utcTime;                    itemEndTime = tmpitem.endDate.utcTime;                } else if (aItemType == calITodo ||                           (tmpitem = item.QueryInterface(calITodo)) != null)                {                    itemStartTime = tmpitem.entryTime.utcTime;                    itemEndTime = tmpitem.entryTime.utcTime;                } else {                    // XXX unknown item type, wth do we do?                    continue;                }                // determine whether any endpoint falls within the range                if ((itemStartTime >= startTime && itemEndTime <= endTime) ||                    (itemStartTime <= startTime && itemEndTime > startTime) ||                    (itemStartTime <= endTime && itemEndTime >= endTime))                {                    itemsFound.push(item);                }                if (aCount && itemsFound.length >= aCount)                    break;            }        }        if (aListener)            aListener.onGetComplete (Components.results.NS_OK,                                     aItemType,                                     null,                                     itemsFound);    },
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/b1bcbb04f2471a1f94d43c23fb08b3677e11d57b/calMemoryCalendar.js/clean/calendar/providers/memory/calMemoryCalendar.js