Add support for visibility animations

Desktop / Chromium - Ian Vollick [chromium.org] - 20 July 2017 14:05 EDT

It is common to animate something away via a transform, bounds, or opacity animation and want to flip a visibility bit upon completion of that transition. Boolean animations are suited to this task. They act as a step function returning the second value when the timing function returns a fraction of 1.0 (and you can use this timing function to adjust the position of the step).

This change also finishes the small bit of plumbing to tick bg color animations.

Bug: None Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel Change-Id: I18ab39570e2de63cbf103a36c10ea1766efc12e8 Reviewed-on: https://chromium-review.googlesource.com/579529 Commit-Queue: Ian Vollick

a31ad58 Add support for visibility animations
cc/animation/animation_curve.cc | 9 +++
cc/animation/animation_curve.h | 28 ++++++--
cc/animation/animation_player.cc | 7 +-
cc/animation/animation_target.h | 7 +-
cc/animation/keyframed_animation_curve.cc | 77 ++++++++++++++++++++
cc/animation/keyframed_animation_curve.h | 56 +++++++++++++++
cc/animation/keyframed_animation_curve_unittest.cc | 82 ++++++++++++++++++++++
cc/trees/target_property.cc | 4 +-
cc/trees/target_property.h | 3 +-
9 files changed, 263 insertions(+), 10 deletions(-)

Upstream: git.chromium.org


  • Share