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

Side by Side Diff: Source/core/animation/InterpolationEffect.cpp

Issue 984153002: Fix template angle bracket syntax in animation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 9 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "config.h" 5 #include "config.h"
6 #include "core/animation/InterpolationEffect.h" 6 #include "core/animation/InterpolationEffect.h"
7 7
8 namespace blink { 8 namespace blink {
9 9
10 void InterpolationEffect::getActiveInterpolations(double fraction, double iterat ionDuration, OwnPtrWillBeRawPtr<WillBeHeapVector<RefPtrWillBeMember<Interpolatio n>>>& result) const 10 void InterpolationEffect::getActiveInterpolations(double fraction, double iterat ionDuration, OwnPtrWillBeRawPtr<WillBeHeapVector<RefPtrWillBeMember<Interpolatio n>>>& result) const
11 { 11 {
12 if (!result) 12 if (!result)
13 result = adoptPtrWillBeNoop(new WillBeHeapVector<RefPtrWillBeMember<Inte rpolation> >()); 13 result = adoptPtrWillBeNoop(new WillBeHeapVector<RefPtrWillBeMember<Inte rpolation>>());
14 14
15 size_t existingSize = result->size(); 15 size_t existingSize = result->size();
16 size_t resultIndex = 0; 16 size_t resultIndex = 0;
17 17
18 for (const auto& record : m_interpolations) { 18 for (const auto& record : m_interpolations) {
19 if (fraction >= record->m_applyFrom && fraction < record->m_applyTo) { 19 if (fraction >= record->m_applyFrom && fraction < record->m_applyTo) {
20 RefPtrWillBeRawPtr<Interpolation> interpolation = record->m_interpol ation; 20 RefPtrWillBeRawPtr<Interpolation> interpolation = record->m_interpol ation;
21 double localFraction = (fraction - record->m_start) / (record->m_end - record->m_start); 21 double localFraction = (fraction - record->m_start) / (record->m_end - record->m_start);
22 if (record->m_easing) 22 if (record->m_easing)
23 localFraction = record->m_easing->evaluate(localFraction, accura cyForDuration(iterationDuration)); 23 localFraction = record->m_easing->evaluate(localFraction, accura cyForDuration(iterationDuration));
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 { 77 {
78 visitor->trace(m_interpolation); 78 visitor->trace(m_interpolation);
79 } 79 }
80 80
81 DEFINE_TRACE(InterpolationEffect) 81 DEFINE_TRACE(InterpolationEffect)
82 { 82 {
83 visitor->trace(m_interpolations); 83 visitor->trace(m_interpolations);
84 } 84 }
85 85
86 } // namespace blink 86 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/animation/InterpolationEffect.h ('k') | Source/core/animation/InterpolationEffectTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698