use timeout only if requestAnimationFrame is not available. A timeout on 0 is actually a timeout on "the next paint cycle", which is specificaly what requestAnimationFrame was designed for.