mozilla-b2g/gaia — pull request #6562 by lmorchard (2012-11-21 22:07:50+00:00)
Title: bug 812556: Reworked calendar conflict layout management

ATTN: @lightsofapollo

This is a mildly scary PR, because I've totally reimplemented `overlap.js` for the non-overlapping layout from the mockups.

In a nutshell, this implementation maintains conflict regions that use IntervalTrees to build columns of non-overlapping events. Those, in turn, are used to update the width and left position for events covered by each conflict region.

It has tests, seems to work in Fx nightly and B2G Desktop, but I can't seem to get my phone updated with gaia right now.

I'm still poking around with performance, and there's at least one add-then-remove use case where the layout doesn't collapse columns in a nice way. Oh, and I probably have lots of lint warning to clean up. But, I figured I might submit this PR to at least get some feedback on the new implementation overall