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

Side by Side Diff: third_party/WebKit/Source/core/animation/InvalidatableInterpolation.cpp

Issue 2562773002: Migrate WTF::Vector::append() to ::push_back() [part 2 of N] (Closed)
Patch Set: rebase Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/animation/InvalidatableInterpolation.h" 5 #include "core/animation/InvalidatableInterpolation.h"
6 6
7 #include "core/animation/InterpolationEnvironment.h" 7 #include "core/animation/InterpolationEnvironment.h"
8 #include "core/animation/StringKeyframe.h" 8 #include "core/animation/StringKeyframe.h"
9 #include "core/css/resolver/StyleResolverState.h" 9 #include "core/css/resolver/StyleResolverState.h"
10 #include <memory> 10 #include <memory>
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 } 75 }
76 DCHECK(keyframe.isNeutral()); 76 DCHECK(keyframe.isNeutral());
77 return nullptr; 77 return nullptr;
78 } 78 }
79 79
80 void InvalidatableInterpolation::addConversionCheckers( 80 void InvalidatableInterpolation::addConversionCheckers(
81 const InterpolationType& type, 81 const InterpolationType& type,
82 ConversionCheckers& conversionCheckers) const { 82 ConversionCheckers& conversionCheckers) const {
83 for (size_t i = 0; i < conversionCheckers.size(); i++) { 83 for (size_t i = 0; i < conversionCheckers.size(); i++) {
84 conversionCheckers[i]->setType(type); 84 conversionCheckers[i]->setType(type);
85 m_conversionCheckers.append(std::move(conversionCheckers[i])); 85 m_conversionCheckers.push_back(std::move(conversionCheckers[i]));
86 } 86 }
87 } 87 }
88 88
89 std::unique_ptr<TypedInterpolationValue> 89 std::unique_ptr<TypedInterpolationValue>
90 InvalidatableInterpolation::maybeConvertUnderlyingValue( 90 InvalidatableInterpolation::maybeConvertUnderlyingValue(
91 const InterpolationEnvironment& environment) const { 91 const InterpolationEnvironment& environment) const {
92 for (const auto& interpolationType : *m_interpolationTypes) { 92 for (const auto& interpolationType : *m_interpolationTypes) {
93 InterpolationValue result = 93 InterpolationValue result =
94 interpolationType->maybeConvertUnderlyingValue(environment); 94 interpolationType->maybeConvertUnderlyingValue(environment);
95 if (result) 95 if (result)
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 currentInterpolation.m_currentFraction); 273 currentInterpolation.m_currentFraction);
274 } 274 }
275 275
276 if (shouldApply && underlyingValueOwner) 276 if (shouldApply && underlyingValueOwner)
277 underlyingValueOwner.type().apply( 277 underlyingValueOwner.type().apply(
278 *underlyingValueOwner.value().interpolableValue, 278 *underlyingValueOwner.value().interpolableValue,
279 underlyingValueOwner.value().nonInterpolableValue.get(), environment); 279 underlyingValueOwner.value().nonInterpolableValue.get(), environment);
280 } 280 }
281 281
282 } // namespace blink 282 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698