Bug 1371450 - Return whether the root element has animation-only dirty bit from Servo_TraverseSubtree for flushing throttled animations. r?emilio
MozReview-Commit-ID: 4wLud7FMQk1
--- a/servo/ports/geckolib/glue.rs
+++ b/servo/ports/geckolib/glue.rs
@@ -278,17 +278,18 @@ pub extern "C" fn Servo_TraverseSubtree(
if needs_animation_only_restyle {
traverse_subtree(element,
raw_data,
traversal_flags | ANIMATION_ONLY,
unsafe { &*snapshots });
}
if restyle_behavior == Restyle::ForThrottledAnimationFlush {
- return needs_animation_only_restyle;
+ return element.has_animation_only_dirty_descendants() ||
+ element.borrow_data().unwrap().restyle.is_restyle();
}
traverse_subtree(element,
raw_data,
traversal_flags,
unsafe { &*snapshots });
if restyle_behavior == Restyle::ForNewlyBoundElement {