Permalink
Browse files

final touches and bugfixes for 1.4.9

  • Loading branch information...
1 parent 6931c87 commit 61d663d4613cd79996079631f3685324106c73ea @arshaw arshaw committed Nov 20, 2010
View
@@ -1,4 +1,9 @@
+version 1.4.9 (11/16/10)
+ - new algorithm for vertically stacking events (issue 111)
+ - resizing an event to a different week (issue 306)
+ - bug: some events not rendered with consecutive calls to addEventSource (issue 679)
+
version 1.4.8 (10/16/10)
- ignoreTimezone option (set to `false` to process UTC offsets in ISO8601 dates)
- bugfixes
View

Large diffs are not rendered by default.

Oops, something went wrong.
View

Large diffs are not rendered by default.

Oops, something went wrong.

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -50,6 +50,7 @@ function Calendar(element, options, eventSources) {
var ignoreWindowResize = 0;
var date = new Date();
var events = [];
+ var _dragElement;
@@ -242,6 +243,7 @@ function Calendar(element, options, eventSources) {
calcSize();
setSize();
unselect();
+ currentView.clearEvents();
currentView.renderEvents(events);
currentView.sizeDirty = false;
}
@@ -468,8 +470,6 @@ function Calendar(element, options, eventSources) {
/* External Dragging
------------------------------------------------------------------------*/
- var _dragElement;
-
if (options.droppable) {
$(document)
.bind('dragstart', function(ev, ui) {
View
@@ -45,11 +45,12 @@ function EventManager(options, sources) {
function fetchEvents(start, end) {
rangeStart = start;
rangeEnd = end;
- currentFetchID++;
cache = [];
- pendingSourceCnt = sources.length;
- for (var i=0; i<sources.length; i++) {
- fetchEventSource(sources[i], currentFetchID);
+ var fetchID = ++currentFetchID;
+ var len = sources.length;
+ pendingSourceCnt = len;
+ for (var i=0; i<len; i++) {
+ fetchEventSource(sources[i], fetchID);
}
}
View
@@ -1,7 +1,7 @@
(function() {
-var JQUERY = 'jquery-1.4.3.min.js';
-var JQUERY_UI = 'jquery-ui-1.8.5.custom.min.js';
+var JQUERY = 'jquery-1.4.4.min.js';
+var JQUERY_UI = 'jquery-ui-1.8.6.custom.min.js';
var JQUERY_LEGACY = 'jquery-1.3.2.min.js';
var JQUERY_UI_LEGACY = 'jquery-ui-1.7.3.custom.min.js';
@@ -79,10 +79,18 @@ function AgendaEventRenderer() {
function compileDaySegs(events) {
- var segs = sliceSegs(events, $.map(events, exclEndDay), t.visStart, t.visEnd),
- i;
- for (i=0; i<segs.length; i++) {
- segs[i].row = 0;
+ var levels = stackSegs(sliceSegs(events, $.map(events, exclEndDay), t.visStart, t.visEnd)),
+ i, levelCnt=levels.length, level,
+ j, seg,
+ segs=[];
+ for (i=0; i<levelCnt; i++) {
+ level = levels[i];
+ for (j=0; j<level.length; j++) {
+ seg = level[j];
+ seg.row = 0;
+ seg.level = i; // not needed anymore
+ segs.push(seg);
+ }
}
return segs;
}
@@ -53,16 +53,21 @@ function BasicEventRenderer() {
d1 = cloneDate(t.visStart),
d2 = addDays(cloneDate(d1), colCnt),
visEventsEnds = $.map(events, exclEndDay),
- i,
- rowSegs,
- j,
+ i, row,
+ j, level,
+ k, seg,
segs=[];
for (i=0; i<rowCnt; i++) {
- rowSegs = sliceSegs(events, visEventsEnds, d1, d2);
- for (j=0; j<rowSegs.length; j++) {
- rowSegs[j].row = i;
+ row = stackSegs(sliceSegs(events, visEventsEnds, d1, d2));
+ for (j=0; j<row.length; j++) {
+ level = row[j];
+ for (k=0; k<level.length; k++) {
+ seg = level[k];
+ seg.row = i;
+ seg.level = j; // not needed anymore
+ segs.push(seg);
+ }
}
- segs = segs.concat(rowSegs);
addDays(d1, 7);
addDays(d2, 7);
}
@@ -165,7 +165,7 @@ function DayEventRenderer() {
:'') +
"<span class='fc-event-title'>" + htmlEscape(event.title) + "</span>" +
"</a>" +
- (seg.isEnd && (event.editable || event.editable === undefined && opt('editable')) && !opt('disableResizing') && $.fn.resizable ?
+ (seg.isEnd && (event.editable || event.editable === undefined && opt('editable')) && !opt('disableResizing') ?
"<div class='ui-resizable-handle ui-resizable-" + (rtl ? 'w' : 'e') + "'></div>"
: '') +
"</div>";
View
@@ -29,7 +29,7 @@ $.fn.fullCalendar = function(options) {
}
- // would like to have this logic in EventManager, but needs to happen before options are extended
+ // would like to have this logic in EventManager, but needs to happen before options are recursively extended
var eventSources = options.eventSources || [];
delete options.eventSources;
if (options.events) {
View
@@ -2,7 +2,7 @@
<html>
<head>
<link rel='stylesheet' type='text/css' href='lib/fancybox/jquery.fancybox-1.2.6.css' />
-<script type='text/javascript' src='../lib/jquery-1.4.3.min.js'></script>
+<script type='text/javascript' src='../lib/jquery-1.4.4.min.js'></script>
<script type='text/javascript' src='lib/fancybox/jquery.fancybox-1.2.6.pack.js'></script>
<script type='text/javascript'>
View
@@ -1 +1 @@
-1.4.8
+1.4.9

0 comments on commit 61d663d

Please sign in to comment.