<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>107609</bug_id>
          
          <creation_ts>2013-01-22 18:05:38 -0800</creation_ts>
          <short_desc>REGRESSION(r139800): animations with start delay may not animate if page becomes hidden</short_desc>
          <delta_ts>2013-04-06 01:39:53 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>New Bugs</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>107521</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter>dstockwell</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>bdakin</cc>
    
    <cc>dino</cc>
    
    <cc>jamesr</cc>
    
    <cc>simon.fraser</cc>
    
    <cc>syoichi</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>813637</commentid>
    <comment_count>0</comment_count>
    <who name="">dstockwell</who>
    <bug_when>2013-01-22 18:05:38 -0800</bug_when>
    <thetext>http://trac.webkit.org/changeset/139800

It&apos;s not clear from the Changelog which of these changes are intentional:

Animation events do not fire while page is hidden.
Animations may not animate if page becomes hidden then visible again during animation-delay.
Animations do not make progress while page is hidden.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>813638</commentid>
    <comment_count>1</comment_count>
    <who name="James Robinson">jamesr</who>
    <bug_when>2013-01-22 18:09:05 -0800</bug_when>
    <thetext>My guess would be all 3 are intentional.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>813647</commentid>
    <comment_count>2</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2013-01-22 18:18:35 -0800</bug_when>
    <thetext>Animation suspend/resume are totally broken; they just stop existing animations, they don&apos;t prevent new ones. Not deliberate, just broken.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>813661</commentid>
    <comment_count>3</comment_count>
    <who name="">dstockwell</who>
    <bug_when>2013-01-22 18:40:16 -0800</bug_when>
    <thetext>(In reply to comment #2)
&gt; Animation suspend/resume are totally broken; they just stop existing animations, they don&apos;t prevent new ones. Not deliberate, just broken.

Can we roll it out, or is work happening on suspend/resume?

If the goal was to reduce CPU usage I think we could still achieve that without suspending by only servicing animations at event points when the page is hidden.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>813732</commentid>
    <comment_count>4</comment_count>
    <who name="Beth Dakin">bdakin</who>
    <bug_when>2013-01-22 20:36:18 -0800</bug_when>
    <thetext>First we should agree on desired behavior. 

(In reply to comment #0)
&gt; http://trac.webkit.org/changeset/139800
&gt; 
&gt; It&apos;s not clear from the Changelog which of these changes are intentional:
&gt; 
&gt; Animation events do not fire while page is hidden.

I tend to think this is correct behavior, but I am open to a discussion.

&gt; Animations may not animate if page becomes hidden then visible again during animation-delay.

Definitely a bug.

&gt; Animations do not make progress while page is hidden.

Personally I like this behavior as well, but I do think it&apos;s open to discussion. 

And Simon pointed out that suspend does not prevent new animations, which is also definitely a bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>813816</commentid>
    <comment_count>5</comment_count>
    <who name="">dstockwell</who>
    <bug_when>2013-01-22 22:04:04 -0800</bug_when>
    <thetext>(In reply to comment #4)
&gt; &gt; Animation events do not fire while page is hidden.
&gt; 
&gt; I tend to think this is correct behavior, but I am open to a discussion.
&gt; 
&gt; &gt; Animations do not make progress while page is hidden.
&gt; 
&gt; Personally I like this behavior as well, but I do think it&apos;s open to discussion. 

I think these are effectively the same issue. I am concerned that this change diverges from IE and Firefox. I think there are many use cases where animations  align with real time and will be impacted/ made more difficult.

eg. http://www.paulrhayes.com/experiments/clock/#clock</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>813826</commentid>
    <comment_count>6</comment_count>
    <who name="Beth Dakin">bdakin</who>
    <bug_when>2013-01-22 22:11:08 -0800</bug_when>
    <thetext>(In reply to comment #5)
&gt; (In reply to comment #4)
&gt; &gt; &gt; Animation events do not fire while page is hidden.
&gt; &gt; 
&gt; &gt; I tend to think this is correct behavior, but I am open to a discussion.
&gt; &gt; 
&gt; &gt; &gt; Animations do not make progress while page is hidden.
&gt; &gt; 
&gt; &gt; Personally I like this behavior as well, but I do think it&apos;s open to discussion. 
&gt; 
&gt; I think these are effectively the same issue. I am concerned that this change diverges from IE and Firefox. I think there are many use cases where animations  align with real time and will be impacted/ made more difficult.
&gt; 
&gt; eg. http://www.paulrhayes.com/experiments/clock/#clock

Hmm! Thank you for that example; it is a compelling demo for the alternate behavior. Thinking this over…</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>820844</commentid>
    <comment_count>7</comment_count>
    <who name="">dstockwell</who>
    <bug_when>2013-01-30 17:12:39 -0800</bug_when>
    <thetext>(In reply to comment #6)
&gt; Hmm! Thank you for that example; it is a compelling demo for the alternate behavior. Thinking this over…

Any thoughts?

I have a patch (https://bugs.webkit.org/attachment.cgi?id=185628) on https://bugs.webkit.org/show_bug.cgi?id=107521 that implements the idea above (only service animations at events for hidden pages) which you could experiment with.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>