From ca4ff2e70c0e5de884c77d5183a603b741f9e05d Mon Sep 17 00:00:00 2001 From: Jason Oster Date: Wed, 8 Jul 2009 18:28:13 +0000 Subject: Fix overlapping events which span a day, fix erroneously adding 15 minutes to events which span a day or more and end on the same time they start, add day-spanning icons in day and week views --- functions/draw_functions.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'functions/draw_functions.php') diff --git a/functions/draw_functions.php b/functions/draw_functions.php index 77564c9..836d41f 100644 --- a/functions/draw_functions.php +++ b/functions/draw_functions.php @@ -1,6 +1,6 @@ gridLength; @@ -24,14 +24,15 @@ function drawEventTimes ($start, $end) { $end_min = "00"; } - if (($sta_h . $sta_min) == ($end_h . $end_min)) { + if ((!$long_event) && (($sta_h . $sta_min) == ($end_h . $end_min))) { $end_min += $gridLength; if ($end_min == 60) { $end_h = sprintf("%02d", ($end_h + 1)); $end_min = "00"; } - } + } $draw_len = ($end_h * 60 + $end_min) - ($sta_h * 60 + $sta_min); + return array ("draw_start" => ($sta_h . $sta_min), "draw_end" => ($end_h . $end_min), "draw_length" => $draw_len); } -- cgit v1.2.3