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

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

Issue 2578043002: Rename apply() in CSSInterpolationType subclasses (Closed)
Patch Set: rebased Created 3 years, 12 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/CSSRotateInterpolationType.h" 5 #include "core/animation/CSSRotateInterpolationType.h"
6 6
7 #include "core/css/resolver/StyleBuilderConverter.h" 7 #include "core/css/resolver/StyleBuilderConverter.h"
8 #include "platform/transforms/RotateTransformOperation.h" 8 #include "platform/transforms/RotateTransformOperation.h"
9 #include "platform/transforms/Rotation.h" 9 #include "platform/transforms/Rotation.h"
10 #include "wtf/PtrUtil.h" 10 #include "wtf/PtrUtil.h"
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 CSSRotateNonInterpolableValue& underlyingNonInterpolableValue = 199 CSSRotateNonInterpolableValue& underlyingNonInterpolableValue =
200 toCSSRotateNonInterpolableValue( 200 toCSSRotateNonInterpolableValue(
201 *underlyingValueOwner.value().nonInterpolableValue); 201 *underlyingValueOwner.value().nonInterpolableValue);
202 const CSSRotateNonInterpolableValue& nonInterpolableValue = 202 const CSSRotateNonInterpolableValue& nonInterpolableValue =
203 toCSSRotateNonInterpolableValue(*value.nonInterpolableValue); 203 toCSSRotateNonInterpolableValue(*value.nonInterpolableValue);
204 double progress = toInterpolableNumber(*value.interpolableValue).value(); 204 double progress = toInterpolableNumber(*value.interpolableValue).value();
205 underlyingValueOwner.mutableValue().nonInterpolableValue = 205 underlyingValueOwner.mutableValue().nonInterpolableValue =
206 underlyingNonInterpolableValue.composite(nonInterpolableValue, progress); 206 underlyingNonInterpolableValue.composite(nonInterpolableValue, progress);
207 } 207 }
208 208
209 void CSSRotateInterpolationType::apply( 209 void CSSRotateInterpolationType::applyStandardPropertyValue(
210 const InterpolableValue& interpolableValue, 210 const InterpolableValue& interpolableValue,
211 const NonInterpolableValue* untypedNonInterpolableValue, 211 const NonInterpolableValue* untypedNonInterpolableValue,
212 InterpolationEnvironment& environment) const { 212 StyleResolverState& state) const {
213 double progress = toInterpolableNumber(interpolableValue).value(); 213 double progress = toInterpolableNumber(interpolableValue).value();
214 const CSSRotateNonInterpolableValue& nonInterpolableValue = 214 const CSSRotateNonInterpolableValue& nonInterpolableValue =
215 toCSSRotateNonInterpolableValue(*untypedNonInterpolableValue); 215 toCSSRotateNonInterpolableValue(*untypedNonInterpolableValue);
216 Rotation rotation = nonInterpolableValue.slerpedRotation(progress); 216 Rotation rotation = nonInterpolableValue.slerpedRotation(progress);
217 environment.state().style()->setRotate( 217 state.style()->setRotate(
218 RotateTransformOperation::create(rotation, TransformOperation::Rotate3D)); 218 RotateTransformOperation::create(rotation, TransformOperation::Rotate3D));
219 } 219 }
220 220
221 } // namespace blink 221 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698