Re: [css3-animations] animation-iteration-count: 0

On Oct 4, 2011, at 9:13 AM, L. David Baron wrote:

> On Tuesday 2011-10-04 17:27 +0200, Øyvind Stenhaug wrote:
>> http://dev.w3.org/csswg/css3-animations/#the-animation-iteration-count-property-
>> 
>> "Negative values for ‘animation-iteration-count’ are treated as zero."
>> 
>> Actually, this sentence is supposed to be removed or changed,
>> according to
>> <http://lists.w3.org/Archives/Public/www-style/2011Mar/0355.html>.
>> Regardless, despite the fact that zero is mentioned here, I can't
>> find any attempt at defining how it's actually supposed to be
>> treated.
>> 
>> (Gecko sends an event for the end of the animation and sometimes
>> fills forwards, WebKit does neither as far as I can tell.)
> 
> It's worth noting (since it might not be obvious -- I missed it at
> first) that the property takes <number> values -- not <integer>.
> Therefore it seems logical to me that animation-iteration-count:
> 0.00001 and animation-iteration-count: 0 should behave in similar
> ways.

The original intent, and the reason for <number>, was that we wanted
  animation-iteration-count: 2.5
to run the animation two and a half times before stopping. Unfortunately,
WebKit never implemented this, and treats the value as an integer.

Simon

Received on Wednesday, 5 October 2011 20:21:41 UTC