Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1323)

Unified Diff: cc/animation/layer_animation_controller.cc

Issue 1637083004: CC Animation: Remove meaningless method from WebLayer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/animation/layer_animation_controller.h ('k') | cc/blink/web_layer_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/animation/layer_animation_controller.cc
diff --git a/cc/animation/layer_animation_controller.cc b/cc/animation/layer_animation_controller.cc
index 8d779515208bd4ac00f0f7610060d280c24da714..6aa254ce4dfa8973f2afeacbc3495615fbfa53b9 100644
--- a/cc/animation/layer_animation_controller.cc
+++ b/cc/animation/layer_animation_controller.cc
@@ -113,35 +113,6 @@ void LayerAnimationController::RemoveAnimation(int animation_id) {
UpdatePotentiallyAnimatingTransform();
}
-void LayerAnimationController::RemoveAnimation(
- int animation_id,
- Animation::TargetProperty target_property) {
- bool removed_transform_animation = false;
- auto does_not_have_id_or_property = [animation_id, target_property](
- const scoped_ptr<Animation>& animation) {
- return animation->id() != animation_id ||
- animation->target_property() != target_property;
- };
- // Since we want to use the animations that we're going to remove, we need to
- // use a stable_parition here instead of remove_if. Remove_if leaves the
- // removed items in an unspecified state.
- auto animations_to_remove = std::stable_partition(
- animations_.begin(), animations_.end(), does_not_have_id_or_property);
- if (animations_to_remove == animations_.end())
- return;
-
- if (target_property == Animation::SCROLL_OFFSET)
- scroll_offset_animation_was_interrupted_ = true;
- else if (target_property == Animation::TRANSFORM &&
- !(*animations_to_remove)->is_finished())
- removed_transform_animation = true;
-
- animations_.erase(animations_to_remove, animations_.end());
- UpdateActivation(NORMAL_ACTIVATION);
- if (removed_transform_animation)
- UpdatePotentiallyAnimatingTransform();
-}
-
void LayerAnimationController::AbortAnimation(int animation_id) {
bool aborted_transform_animation = false;
if (Animation* animation = GetAnimationById(animation_id)) {
« no previous file with comments | « cc/animation/layer_animation_controller.h ('k') | cc/blink/web_layer_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698