[whatwg] window.setInterval if visible.

On 10/15/09 3:35 PM, Gregg Tavares wrote:
> I was wondering if there as been a proposal for either an optional
> argument to setInterval that makes it only callback if the window is
> visible OR maybe a window.setRenderInterval.

You might be interested in 
for some more discussion about approaches to this problem.  In 
particular, that proposal tries to address overeager animations in 
visible windows as well.

Note, by the way, that testing whether a window is "visible" is not 
cheap; testing whether an element is "visible" is even less cheap....


Received on Thursday, 15 October 2009 12:46:04 UTC