Add tracker and accumulator; fix lots of bugs in window manager