Merge changes I08fcd278,I1f496bb7

* changes:
  Detect animation completions like we used to. Previous approximations weren't indicating completion and windows weren't being layered correctly as a result.
  debug