Commit Graph

602 Commits

Author SHA1 Message Date
Narcis Beleuzu
b0e8772dcd Backed out 6 changesets (bug 1237454) for bc failures on /browser_toolbariconcolor_restyles.js. CLOSED TREE
Backed out changeset f8d771835fd2 (bug 1237454)
Backed out changeset 2dbbfc331bdf (bug 1237454)
Backed out changeset c481f409feaa (bug 1237454)
Backed out changeset 0b9872865f0e (bug 1237454)
Backed out changeset 43ca55e7c93b (bug 1237454)
Backed out changeset 027b0c65d944 (bug 1237454)
2018-02-06 11:19:56 +02:00
Hiroyuki Ikezoe
835e2883de Bug 1237454 - Throttle animations on visibility:hidden element. r=birtles,boris,emilio
This patch does basically throttle animations on visibility:hidden element
and unthrottle it once the animating element became visible or a child of the
animating element became visible.  But still there are some cases that we don't
throttle such animations perfectly.  For example;

  div.style.visibility = 'hidden'; // the 'div' has no children at this moment
  div.animate(..);
  // The animation is throttled

  div.appendChild(visibleChild);
  // The animation isn't throttled

  visibleChild.style.visibility = 'hidden';
  // Now the animation should be throttled again, but actually it's not.

To throttle this case properly, when the |visibleChild|'s visibility changed
to hidden, we would need to do either

 1) Check all siblings of the |visibleChild| have no visible children

or

 2) The parent element stores visible children count somewhere and decrease it
    and check whether the count is zero

To achieve 1) we need to walk up ancestors and their siblings, actually it's
inefficient.

2) is somewhat similar to what we already do for animating images but it's hard
to reuse it for CSS animations since it does not take into account that
descendants' visibilities.

Another example that this patch does not optimize is the the case where
animating element has children whose visibility is inherited and the element
itself initially visible something like this;

  let child = document.createElement('div'); // child visibility is 'inherit'
  div.appendChild(child);

  div.animate(..); // the 'div' is visible
  // The animation isn't throttled since the animating element is visible

  div.style.visiblily = 'hidden';
  // Now the animation should be throttled, but it's not since this patch does
  // not descend down all descendants to check they are invisible or not when the
  // animating element visibility changed to hidden.

This patch adds a test case for this case introduced with todo_is().

Another test case added in this patch fails if we don't use
nsPlaceholderFrame::GetRealFrameFor() in HasNoVisibleDescendants().

MozReview-Commit-ID: BJwzQvP9Yc4

--HG--
extra : rebase_source : ceb95bdce1042cbfc16751d6d023fc6feee5845e
2018-02-06 08:43:53 +09:00
Hiroyuki Ikezoe
dd32a9658a Bug 1237454 - Test for an animation on visibility: hidden element which has grandchild. r=boris
MozReview-Commit-ID: C0yLy4clwbY

--HG--
extra : rebase_source : 0203237cf1bc45941188393e7d9ed7e96072ae91
2018-02-06 08:43:52 +09:00
Hiroyuki Ikezoe
6b8d6a0897 Bug 1237454 - Test for an animation on a visibility:hidden element which has a child. r=boris
MozReview-Commit-ID: AfmQJThhp8d

--HG--
extra : rebase_source : ed4abf7fb865cf8459294f086a63b13bf0d57373
2018-02-06 08:43:52 +09:00
Hiroyuki Ikezoe
3f041debf1 Bug 1237454 - Test for an animation in the parent element whose visibility is changed. r=boris
MozReview-Commit-ID: BBMOuPimlPH

--HG--
extra : rebase_source : b73d6890ddf11f58cd7b623f92a73d7e4bd26e08
2018-02-06 08:43:52 +09:00
Hiroyuki Ikezoe
862a7ba92f Bug 1237454 - An additional check that an animation on visibility: hidden element starts restyling when the element gets visible. r=boris
MozReview-Commit-ID: 2Lvk2IqEaXY

--HG--
extra : rebase_source : 39cea20c92996b6a785576ded71b5c17f61d3457
2018-02-06 08:43:52 +09:00
Hiroyuki Ikezoe
0de04971ef Bug 1237454 - Add VisibilityChange change hint. r=emilio
This new change hint doesn't influence layout so that it can be regarded
as nsChangeHint_Hints_CanIgnoreIfNotVisible.  Note that if visibility changed
from collapse or to collapse, we set NS_STYLE_HINT_REFLOW separetely.

MozReview-Commit-ID: AirDWeBYVKG

--HG--
extra : rebase_source : 1cd03a78a522b1a6965ba73ebf002ddacb0ab4f2
2018-02-06 08:43:52 +09:00
Boris Zbarsky
7a9f022f1a Bug 1434819 part 7. Remove the SHOW_* constants from nsIDOMNodeFilter. r=qdot
MozReview-Commit-ID: 7E2KZkLfbSI
2018-02-01 14:26:12 -05:00
Hiroyuki Ikezoe
0bb119e341 Bug 1428692 - Don't use tweakExpectedRestyleCount in the case where we don't use the returned count for observeStyling called right after. r=birtles
tweakExpectedRestyleCount() is supposed to work with observeStyle() which is
called right after tweakExpectedRestyleCount().  That's because
tweakExpectedRestyleCount() adjusts the expected restyle count which will
happen in continuous frames that begins from the startsRightNow() call,
especially a redundant restyle might be observed in the last frame if the
animation did not begin at the current timeline time and if the Promise inside
the last requestAnimationFrame is fulfilled after restyling happened.

Instead of using tweakExpectedRestyleCount(), we need to check whether the
animation begun at the current timeline time when the animation started, and if
the animation begun at the current timeline time, we don't observe the
superfluous restyle in a frame after the animation element was re-attached.

MozReview-Commit-ID: 6TLQERSSbjU

--HG--
extra : rebase_source : 1a1dcb56b889bebedb44346bbc315ec01870cf79
2018-01-30 06:41:31 +09:00
Hiroyuki Ikezoe
2529df076a Bug 1430654 - Use assert_times_equal for comparing timing values. r=birtles
MozReview-Commit-ID: CUn1f8M0jo5

--HG--
extra : rebase_source : 1ac203d28022707f1b34757a1613e6f201a1f706
2018-01-22 14:57:57 +09:00
Hiroyuki Ikezoe
0a91cefd01 Bug 1430654 - Double epsilon value for assert_times_equal. r=birtles
Since the function assumes that both of actual and expected values
have the same precision requirements.

MozReview-Commit-ID: 4C3TAH6mUVg

--HG--
extra : rebase_source : 1e40e489745b0d9047d34e851a5f043db616323e
2018-01-22 14:57:57 +09:00
Hiroyuki Ikezoe
fae9243927 Bug 1430654 - Introduce assert_time_equals_literal and use it. r=birtles
This assertion is supposed to be used where the first argument has a tolerance
but the second argument doesn't have such tolerance.  Whereas
assert_times_equal() is supposed to be used for the case both arguments have
the same tolerance, actually it hasn't, it will be fixed in a subsequent patch
in this patch series.

MozReview-Commit-ID: FEDHilbX2rm

--HG--
extra : rebase_source : e773902b474bd9a411e7bb3f234702a93547ebba
2018-01-22 14:55:16 +09:00
Wei-Cheng Pan
e8f46bbec4 Bug 1425213 - Unthrottle transform animations regardless in overflowable frames or not. r=hiro
Because we don't know whether the transformed position will be visible or not.
2018-01-17 22:44:00 +02:00
Hiroyuki Ikezoe
ddaf0ef84e Bug 1419079 - Don't bail out from CalculateCumulativeChangeHint() in the case of opacity property even if there is a missing keyframe or composite operation is not 'replace'. r=birtles
For opacity property, we only generate nsChangeHint_UpdateUsesOpacity,
nsChangeHint_UpdateOpacityLayer and nsChangeHint_RepaintFrame.  All of them are
included in nsChangeHint_Hints_CanIgnoreIfNotVisible.  So we can throttle
opacity animations on out-of-view elements whatever underlying opacity value is.

MozReview-Commit-ID: FdQJbItAndG

--HG--
extra : rebase_source : d011270e4e3e1adc1782665a592fb3fac60f9174
2018-01-17 11:48:20 +09:00
Hiroyuki Ikezoe
b72cfe5bff Bug 1419079 - Add a test case for additive animation with a missing keyframe. r=birtles
MozReview-Commit-ID: 5UWfDIx7RVi

--HG--
extra : rebase_source : 17c9e62f66c7fef101a6b2a4f93e4348e94721cf
2018-01-17 08:55:00 +09:00
Hiroyuki Ikezoe
cb10669b24 Bug 1419079 - Revise a comment for a test case for missing keyframes. r=birtles
The animation in the test case is not actually additive animation, it's just a
missing keyframe animation and its composite operation is actually 'replace'.

MozReview-Commit-ID: 4A29V5Ke2hF

--HG--
extra : rebase_source : 63b6c7f52943786d06c52b9baa7e0f4f151781ac
2018-01-17 08:55:00 +09:00
Hiroyuki Ikezoe
c5899c8bd2 Bug 1419079 - Drop checking the pref for offscreen throttling. r=birtles
The pref has been enabled by default since firefox 49, so it's not worth
checking the pref in test.

MozReview-Commit-ID: 5ADIFaV1ue

--HG--
extra : rebase_source : 8490cc7988cc1e7fe3a650c4f1334b4ed11c7105
2018-01-17 08:55:00 +09:00
Hiroyuki Ikezoe
65c0f821c8 Bug 1419079 - Drop checking the pref for animations-api core in file_restyles.html. r=birtles
It's already specified to true in test_restyles.html.

MozReview-Commit-ID: JMItunKYwIs

--HG--
extra : rebase_source : d54368a93857d8d2a86220be55091735caa074e9
2018-01-17 08:55:00 +09:00
Brian Birtles
5a753e5e80 Bug 1429671 - Make composite member of Keyframe dictionary objects accept null values; r=bz
This patch reflects the following change to the Web Animations spec:

  abf76745b5

MozReview-Commit-ID: A2GD1igUf5f

--HG--
extra : rebase_source : 8129f6386b144adebc3bf0320ca7d6bfbba7a2e9
2018-01-11 16:20:49 +09:00
Tom Ritter
3af00498bc Bug 1429668 Turn off the reduceTimerPrecision pref for one more test r=hiro
MozReview-Commit-ID: J7F502Oz3Uc

--HG--
extra : rebase_source : 6b9883e72fad25d985ba61a999a4bdd2468784b0
2018-01-10 23:06:04 -06:00
Tom Ritter
2eeb5f801e Bug 1424341 Turn the pref off for existing tests that perform fine-grained timing comparisons r=mrbkap
MozReview-Commit-ID: 4ZyE4ebaCaB

--HG--
extra : rebase_source : 80a138ba722c64885a5f6811d862bdc76389a000
2018-01-10 14:46:34 -06:00
Hiroyuki Ikezoe
606a9e9a90 Bug 1421507 - Throttle animations in position:fixed element that the element is out of view. r=boris,tnikkel
MozReview-Commit-ID: jLvrcVhTKW

--HG--
extra : rebase_source : e2ff1e0158aa5207f86c47088283c22febe84197
2018-01-05 10:30:46 +09:00
Hiroyuki Ikezoe
9b4b9f9e65 Bug 1421507 - Test cases for position:absolute element. r=boris
MozReview-Commit-ID: IRPsvJ5WAQF

--HG--
extra : rebase_source : 5c6988a9af8392cc5abf54e56060dcf9653edffb
2018-01-05 10:30:17 +09:00
Hiroyuki Ikezoe
68625f879b Bug 1427868 - Run skipped test cases for scrolled-out elements on Android. r=birtles
These tests can be passed now, I don't know what fixed them, presumably
bug 1421476 and bug 1379515 fixed it.

MozReview-Commit-ID: 2srFKTWWvK

--HG--
extra : rebase_source : 418d366ade78d5a9994cb9bbbab39c4c0b42a2a4
2018-01-04 15:22:34 +09:00
Hiroyuki Ikezoe
b47d85dec0 Bug 1425009 - Take into account the possibility that the animation begins at the moment when the animation was detached from the document. r=birtles
MozReview-Commit-ID: wbM5JW7v76

--HG--
extra : rebase_source : c7ec443f86c6be573ac443f05fdf38a1ed97eefd
2018-01-04 10:19:08 +09:00
Hiroyuki Ikezoe
faa768c4fa Bug 1309198 - Test case that document is discarded while Document.getAnimations(). r=smaug 2017-12-21 11:40:23 +09:00
Hiroyuki Ikezoe
76f404fa5c Bug 1425771 - Add a branch in only_one_restyling_after_finish_is_called for the conformant Promise handling. r=birtles
Animation.finish() in a micro task for Animation.ready leads to a restyle and
a redundant restyle due to bug 1415457.  The redundant restyle has been observed
in a single frame without the conformant Promise handling.  But once we have the
conformant Promise handling we can tell it in a later frame.
(see https://bugzilla.mozilla.org/show_bug.cgi?id=1415457#c1 to know what's
going on there)

MozReview-Commit-ID: FoojunfYZ6k

--HG--
extra : rebase_source : 2820dce4513329fb648ef387d58cac469f680a6d
2017-12-18 14:19:39 +09:00
Hiroyuki Ikezoe
263cb0e605 Bug 1425771 - Tweak expected restyle count for the case where the animation begins at the current time. r=birtles
The expected restyle count depends both on animation state and micro task
handling.

If we have the conformant Promise handling and if the animation begins at the
current time, we will observe 1 less restyles than observed frames since we
skip the first restyle in the initial frame.  This represents correctly what
we do and what we *should* do.

If we don't have the conformant Promise handling and if the animation doesn't
begin at the current time, we will observe 1 more restyles than obsered frames
since the Promise in observeStyling (precisely the Promise is inside the
callback for requestAnimationFrame) is fulfilled once after a restyling process
followed by the requestAnimationFrame.

MozReview-Commit-ID: FLhSRx4y1V7

--HG--
extra : rebase_source : 59e2bb2439f69bc1415a441c0b84a81463d8229f
2017-12-18 14:19:26 +09:00
Hiroyuki Ikezoe
605f3607fa Bug 1425771 - Add a another variant of restyling_transform_animations_in_scrolled_out_element for the conformant Promise handling. r=birtles
The test case checks document timeline's currentTime to make sure that we are
in the first frame which happened after 200ms since the animation started.  It
is unfortunate for us from the point of view of restyling that the first frame
includes the restyling process in the frame without the conformant Promise
handling, doesn't include the process with the Promise handling.  So we need
to tweak there depends on the Promise handling.

I did intentionally add the forked version of the function with the same name
since branching depending on the conformant flag inside the original function
will be hard to understand and also we can easily remove the original version
once we have the conformant Promise handling.

FWIW, here is the diff between them:

@@ -365,6 +365,9 @@ waitForAllPaints(() => {

       await SpecialPowers.pushPrefEnv({ set: [["ui.showHideScrollbars", 1]] });

+      // Make sure we start from the state right after requestAnimationFrame.
+      await waitForFrame();
+
       var parentElement = addDiv(null,
         { style: 'overflow-y: scroll; height: 20px;' });
       var div = addDiv(null,
@@ -379,13 +382,17 @@ waitForAllPaints(() => {
       var markers;
       var now;
       while (true) {
-        markers = await observeStyling(1);
-        // Check restyle markers until 200ms is elapsed.
         now = document.timeline.currentTime;
         if ((now - timeAtStart) >= 200) {
+          // If the current time has elapsed over 200ms since the animation was
+          // created, it means that the animation should have already
+          // unthrottled in this tick, let's see what observes in this tick's
+          // restyling process.
+          markers = await observeStyling(1);
           break;
         }

+        markers = await observeStyling(1);
         is(markers.length, 0,
            'Transform animation running on the element which is scrolled out ' +
            'should be throttled until 200ms is elapsed');

MozReview-Commit-ID: 3WfY6aVnsXk

--HG--
extra : rebase_source : ddf51217f03fc1bfe421c344a7a7811dc591a9af
2017-12-18 14:18:17 +09:00
Hiroyuki Ikezoe
90dcb12748 Bug 1425771 - Add a function to check detect whether have conformant Promise handling and set the flag to represent it. r=birtles
MozReview-Commit-ID: FbzaUBKQ47F

--HG--
extra : rebase_source : ae936432d4ccb3e069608703c586d7134d52d12e
2017-12-18 14:17:44 +09:00
Kartikaya Gupta
4f18e92ffb Bug 1334189 - Enable mochitest-plain for linux64-qr. r=jrmuizel
MozReview-Commit-ID: nbcWhDq5de

--HG--
extra : rebase_source : 25e2c2b8b996ae11cd25dee07d9092ba574a9e40
2017-12-13 18:38:39 -05:00
Cosmin Sabou
4d17a4cc2e Backed out 4 changesets (bug 1425771) for ESlint failure r=backout on a CLOSED TREE
Backed out changeset 984d714aa987 (bug 1425771)
Backed out changeset 848047469b27 (bug 1425771)
Backed out changeset a28293b06afe (bug 1425771)
Backed out changeset 14c5ca99af0c (bug 1425771)
2017-12-18 08:37:10 +02:00
Hiroyuki Ikezoe
83ec4ebbf0 Bug 1425771 - Add a branch in only_one_restyling_after_finish_is_called for the conformant Promise handling. r=birtles
Animation.finish() in a micro task for Animation.ready leads to a restyle and
a redundant restyle due to bug 1415457.  The redundant restyle has been observed
in a single frame without the conformant Promise handling.  But once we have the
conformant Promise handling we can tell it in a later frame.
(see https://bugzilla.mozilla.org/show_bug.cgi?id=1415457#c1 to know what's
going on there)

MozReview-Commit-ID: FoojunfYZ6k

--HG--
extra : rebase_source : 2820dce4513329fb648ef387d58cac469f680a6d
2017-12-18 14:19:39 +09:00
Hiroyuki Ikezoe
8d960ec192 Bug 1425771 - Tweak expected restyle count for the case where the animation begins at the current time. r=birtles
The expected restyle count depends both on animation state and micro task
handling.

If we have the conformant Promise handling and if the animation begins at the
current time, we will observe 1 less restyles than observed frames since we
skip the first restyle in the initial frame.  This represents correctly what
we do and what we *should* do.

If we don't have the conformant Promise handling and if the animation doesn't
begin at the current time, we will observe 1 more restyles than obsered frames
since the Promise in observeStyling (precisely the Promise is inside the
callback for requestAnimationFrame) is fulfilled once after a restyling process
followed by the requestAnimationFrame.

MozReview-Commit-ID: FLhSRx4y1V7

--HG--
extra : rebase_source : 59e2bb2439f69bc1415a441c0b84a81463d8229f
2017-12-18 14:19:26 +09:00
Hiroyuki Ikezoe
71ad758afd Bug 1425771 - Add a another variant of restyling_transform_animations_in_scrolled_out_element for the conformant Promise handling. r=birtles
The test case checks document timeline's currentTime to make sure that we are
in the first frame which happened after 200ms since the animation started.  It
is unfortunate for us from the point of view of restyling that the first frame
includes the restyling process in the frame without the conformant Promise
handling, doesn't include the process with the Promise handling.  So we need
to tweak there depends on the Promise handling.

I did intentionally add the forked version of the function with the same name
since branching depending on the conformant flag inside the original function
will be hard to understand and also we can easily remove the original version
once we have the conformant Promise handling.

FWIW, here is the diff between them:

@@ -365,6 +365,9 @@ waitForAllPaints(() => {

       await SpecialPowers.pushPrefEnv({ set: [["ui.showHideScrollbars", 1]] });

+      // Make sure we start from the state right after requestAnimationFrame.
+      await waitForFrame();
+
       var parentElement = addDiv(null,
         { style: 'overflow-y: scroll; height: 20px;' });
       var div = addDiv(null,
@@ -379,13 +382,17 @@ waitForAllPaints(() => {
       var markers;
       var now;
       while (true) {
-        markers = await observeStyling(1);
-        // Check restyle markers until 200ms is elapsed.
         now = document.timeline.currentTime;
         if ((now - timeAtStart) >= 200) {
+          // If the current time has elapsed over 200ms since the animation was
+          // created, it means that the animation should have already
+          // unthrottled in this tick, let's see what observes in this tick's
+          // restyling process.
+          markers = await observeStyling(1);
           break;
         }

+        markers = await observeStyling(1);
         is(markers.length, 0,
            'Transform animation running on the element which is scrolled out ' +
            'should be throttled until 200ms is elapsed');

MozReview-Commit-ID: 3WfY6aVnsXk

--HG--
extra : rebase_source : ddf51217f03fc1bfe421c344a7a7811dc591a9af
2017-12-18 14:18:17 +09:00
Hiroyuki Ikezoe
25e6b9fd45 Bug 1425771 - Add a function to check detect whether have conformant Promise handling and set the flag to represent it. r=birtles
MozReview-Commit-ID: FbzaUBKQ47F

--HG--
extra : rebase_source : ae936432d4ccb3e069608703c586d7134d52d12e
2017-12-18 14:17:44 +09:00
Brian Birtles
0fec9ac501 Bug 1425548 - Update references to Web Animations spec in dom/animation; r=hiro
MozReview-Commit-ID: 1f2Mz0VhnBm

--HG--
extra : rebase_source : 30c952ed20ee64810d225e5778650dd01791964d
2017-12-15 14:55:08 -06:00
Hiroyuki Ikezoe
958d16759c Bug 1424949 - Wait for one more frame before checking animation start time to avoid the situation that the animation just begins at the time when it's ready. r=birtles
MozReview-Commit-ID: 6bNfl10TiT6

--HG--
extra : rebase_source : 095fd007710f8a7af13e2e7331f7326554f32cb7
2017-12-15 01:36:04 +09:00
Hiroyuki Ikezoe
c9071bce5c Bug 1424949 - Use assert_greater_than or assert_less_than in file_animations-dynamic-changes.html. r=birtles
MozReview-Commit-ID: I24yopOv51d

--HG--
extra : rebase_source : cd57a9649a3ff1335112f1240e1fcfe694a053d5
2017-12-15 01:24:57 +09:00
Hiroyuki Ikezoe
33d26976c8 Bug 1424948 - Check iteration progress value instead of animating computed style value. r=birtles
It is possible that animating computed style becomes the same value as the
value in the previous tick if Animation.mPendingReadyTime is pretty close
to the timeline current time.

MozReview-Commit-ID: COuur4Wlufx

--HG--
extra : rebase_source : 5dea9ef0bce7cb606dc290277e04b779fe608bbd
2017-12-15 01:10:11 +09:00
Hiroyuki Ikezoe
2a72c4f2f9 Bug 1424948 - Use waitForNextFrame instead of waitForFrame. r=birtles
MozReview-Commit-ID: AZJ7LyeIKq2

--HG--
extra : rebase_source : f42d2b0d4220d3d458093fdc5aed7ff11dcff63e
2017-12-15 00:06:26 +09:00
Hiroyuki Ikezoe
29d095f24f Bug 1416966 - Drop the check for the new micro task checkpoint for animations. r=birtles
MozReview-Commit-ID: HVxDrxV3Qmb

--HG--
extra : rebase_source : 9b29646a35e23c31896ae7458c49a8abd44bacbb
2017-12-12 18:44:05 +09:00
Hiroyuki Ikezoe
280df82ed9 Bug 1416966 - Perform a micro task checkpoint in DocumentTimeline::WillRefresh. r=bevis,birtles
MozReview-Commit-ID: Kd1Il7COZZY

--HG--
extra : rebase_source : 872267be92883ed5f94b2e4dbca7fd7f24941f34
2017-12-12 18:44:05 +09:00
Hiroyuki Ikezoe
fedaef24c4 Bug 1416966 - Add an annotation for a test case that will fail once we perform a micro task checkpoint between Animation::Tick and requestAnimationFrame callbacks. r=birtles
The 'is' check there will be replaced 'todo_is' after the commit for the new
micro task checkpoint.

MozReview-Commit-ID: EGFZWy8BD3O

--HG--
extra : rebase_source : 034717a9e7aac0edb82613321ec056ed07cdb996
2017-12-12 18:44:04 +09:00
Hiroyuki Ikezoe
912d3bc83e Bug 1416966 - Count a remaining animation restyle request when animating element was detached from the document. r=birtles
If element which has script animations is detached between Animation::Tick and
styling process, the element persists in EffectCompositor::mElementsToRestyle
(bug 1417354).  When the element is attached to the document again, the element
in mElementsToRestyle is considered as a target element that needs to be
traversed in the first animation-only restyling.  Thus the remaining restyle
request can be observed with the new micro task checkpoint for animations.

MozReview-Commit-ID: F6gs2QXcZ8X

--HG--
extra : rebase_source : 09ccf76e4d28ee55facc5a62f3e8f08e0eeb3e03
2017-12-12 18:44:04 +09:00
Hiroyuki Ikezoe
e49eb2dc18 Bug 1416966 - Add todo for checking one restyle after Animation.pause(). r=birtles
Similar to the previous commit, if Animation.pause() is called between
restyling process and the next refresh driver's tick and if we wait for
Animation.ready after the pause(), there should be one restyle that hasn't
yet processed.

MozReview-Commit-ID: JnpwhOuDvPz

--HG--
extra : rebase_source : b6f14e05837754d1bd51c8a50ce8d82a0c7d751a
2017-12-12 18:44:04 +09:00
Hiroyuki Ikezoe
cdb5d751e5 Bug 1416966 - Add todo for checking the final restyle after Animation.finished. r=birtles
If Animation.finished promise was fulfilled in Animation::Tick, at the moment we
haven't yet restyled the final animation value.  So once we have new micro task
checkpoint there we can observe a restyle marker after Animation.finished was
fulfilled.

MozReview-Commit-ID: LiEl4Iu2Cbr

--HG--
extra : rebase_source : d88b037eba2fd07d75a3ab429c028e23e5137b52
2017-12-12 18:44:04 +09:00
Hiroyuki Ikezoe
e792071575 Bug 1424644 - Check pending state to make sure the animation has been paused or not. r=birtles
'finish_from_pause' supposes that finish() is called after pause pending state
is finished.  Whereas 'finish_from_pause_pending' supposes that finish() is
called during pause pending state.  We should check the state respectively.

MozReview-Commit-ID: DUq2ghK6h9I

--HG--
extra : rebase_source : 2d4ded71387e75efcff9bb184b8e51475bc8bc56
2017-12-11 06:46:46 +09:00
Hiroyuki Ikezoe
e8357d3715 Bug 1424115 - Rewrite test_animation_observers_async.html with promise_test. r=boris
With this patch we still use a global MutationObserver and a single target
element and re-use them in all test cases.  Eventually each test should create
a target element and a MutationObserver to avoid explicit cleanup jobs (e.g.
clearing styles and flushing styles for the global target element), but it's
not in the scope of this bug.

MozReview-Commit-ID: IqEjMbTrpAK

--HG--
extra : rebase_source : 7463c21ce946f5c15f2b7bc4a71c90dba784385d
2017-12-08 12:03:30 +09:00
Hiroyuki Ikezoe
dc512a2632 Bug 1424115 - Drop EventUtils.js from test_animation_observers_async.html. r=boris
It's no longer used.

MozReview-Commit-ID: 5f4lEP5wAqx

--HG--
extra : rebase_source : 81feae35ee4ee735e2bb3904f0166897c93880ec
2017-12-08 11:50:03 +09:00