1.1 --- a/EventAggregatorSupport/Filter.py Tue Jan 28 23:30:33 2014 +0100
1.2 +++ b/EventAggregatorSupport/Filter.py Wed Jan 29 19:20:21 2014 +0100
1.3 @@ -198,8 +198,8 @@
1.4 Return a scale for the given coverage so that the times involved are
1.5 exposed. The scale consists of a list of non-overlapping timespans forming
1.6 a contiguous period of time, where each timespan is accompanied in a tuple
1.7 - by a limit and a list of original time details. Thus, the scale consists of
1.8 - (timespan, limit, set-of-times) tuples.
1.9 + by a limit and two sets of original time details. Thus, the scale consists
1.10 + of (timespan, limit, set-of-start-times, set-of-end-times) tuples.
1.11 """
1.12
1.13 times = {}
1.14 @@ -241,7 +241,7 @@
1.15
1.16 for time, limit in keys:
1.17 if not first:
1.18 - scale.append((Timespan(start, time), limit, times[(start, start_limit)]))
1.19 + scale.append((Timespan(start, time), limit, times[(start, start_limit)], times[(time, limit)]))
1.20 else:
1.21 first = 0
1.22 start, start_limit = time, limit
2.1 --- a/EventAggregatorSupport/View.py Tue Jan 28 23:30:33 2014 +0100
2.2 +++ b/EventAggregatorSupport/View.py Wed Jan 29 19:20:21 2014 +0100
2.3 @@ -1339,7 +1339,7 @@
2.4
2.5 day_rows = []
2.6
2.7 - for period, limit, times in scale:
2.8 + for period, limit, start_times, end_times in scale:
2.9
2.10 # Ignore timespans before this day.
2.11
2.12 @@ -1363,7 +1363,7 @@
2.13 rowspans[event] += 1
2.14 day_row.append((location, event))
2.15
2.16 - day_rows.append((period, day_row, times))
2.17 + day_rows.append((period, day_row, start_times, end_times))
2.18
2.19 # Output the locations.
2.20
2.21 @@ -1393,7 +1393,7 @@
2.22 last_period = period = None
2.23 events_written = set()
2.24
2.25 - for period, day_row, times in day_rows:
2.26 + for period, day_row, start_times, end_times in day_rows:
2.27
2.28 # Write a heading describing the time.
2.29
2.30 @@ -1402,7 +1402,7 @@
2.31 # Show times only for distinct periods.
2.32
2.33 if not last_period or period.start != last_period.start:
2.34 - append(self.writeDayScaleHeading(times))
2.35 + append(self.writeDayScaleHeading(start_times))
2.36 else:
2.37 append(self.writeDayScaleHeading([]))
2.38
2.39 @@ -1432,7 +1432,7 @@
2.40 if period is not None:
2.41 if period.end == date:
2.42 append(fmt.table_row(on=1))
2.43 - append(self.writeDayScaleHeading(times))
2.44 + append(self.writeDayScaleHeading(end_times))
2.45
2.46 for slot in day_row:
2.47 append(self.writeDaySpacer())