W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2009

Re: setTimeout() in HTML5

From: Ian Hickson <ian@hixie.ch>
Date: Mon, 4 May 2009 17:29:37 +0000 (UTC)
To: Giovanni Campagna <scampa.giovanni@gmail.com>
Cc: Maciej Stachowiak <mjs@apple.com>, "public-webapps@w3.org Group WG" <public-webapps@w3.org>
Message-ID: <Pine.LNX.4.62.0905041724130.7824@hixie.dreamhostps.com>
On Mon, 4 May 2009, Giovanni Campagna wrote:
> 2009/5/4 Ian Hickson <ian@hixie.ch>:
> > On Mon, 4 May 2009, Giovanni Campagna wrote:
> >> 2009/5/4 Ian Hickson <ian@hixie.ch>:
> >> > On Fri, 3 Oct 2008, Maciej Stachowiak wrote:
> >> >>
> >> >> I would recommend to the HTML5 editor to require some reasonable 
> >> >> minimum because it seems to be de facto required for Web 
> >> >> compatibility. I cannot state with certainty that nothing lower 
> >> >> than 10ms is safe. Chrome shipped with a 1ms delay and that was 
> >> >> found to create problems on a number of sites, including nytimes. 
> >> >> They are planning to try 4ms next. We would consider using a lower 
> >> >> limit in the official webkit.org version of WebKit, not not as low 
> >> >> as 1ms.
> >> >
> >> > I've used 4ms for now but will increase it if that is found to be 
> >> > too low.
> >> >
> >> > I used 10ms for setInterval().
> >>
> >> I would like to see a maximum too, as well as clearly defined error 
> >> behavior for values outside the allowed range. This because I found 
> >> very strange when Firefox turned an infinite timeout into 1ms.
> >
> > The spec already defines this actually.
> 
> Sorry, my mistake: I wrote infinite, but I actually meant really long 
> but inside the range of a valid integer.

That is also already defined. The spec uses ECMAScript's ToNumber() 
operator and requires support of the entire range of numbers this could 
result in.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Monday, 4 May 2009 17:30:13 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:31 GMT