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

Unified Diff: Source/core/page/animation/KeyframeAnimation.cpp

Issue 20294002: Fix trailing whitespace in .cpp, .h, and .idl files (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years, 5 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 | « Source/core/page/animation/KeyframeAnimation.h ('k') | Source/core/page/scrolling/ScrollingConstraints.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/page/animation/KeyframeAnimation.cpp
diff --git a/Source/core/page/animation/KeyframeAnimation.cpp b/Source/core/page/animation/KeyframeAnimation.cpp
index 220bac16624bf57187aa9e9a2972e1bb6f4572d2..9e9de9d2e5c1d3fc243bb7559992d0d04ea2fdf8 100644
--- a/Source/core/page/animation/KeyframeAnimation.cpp
+++ b/Source/core/page/animation/KeyframeAnimation.cpp
@@ -6,13 +6,13 @@
* are met:
*
* 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
+ * notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
+ * documentation and/or other materials provided with the distribution.
* 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of
* its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
+ * from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
@@ -91,7 +91,7 @@ void KeyframeAnimation::fetchIntervalEndpointsForProperty(CSSPropertyID property
size_t numKeyframes = m_keyframes.size();
if (!numKeyframes)
return;
-
+
ASSERT(!m_keyframes[0].key());
ASSERT(m_keyframes[m_keyframes.size() - 1].key() == 1);
@@ -150,7 +150,7 @@ void KeyframeAnimation::fetchIntervalEndpointsForProperty(CSSPropertyID property
fromStyle = prevKeyframe.style();
toStyle = nextKeyframe.style();
-
+
offset = prevKeyframe.key();
scale = 1.0 / (nextKeyframe.key() - prevKeyframe.key());
@@ -165,7 +165,7 @@ void KeyframeAnimation::animate(CompositeAnimation*, RenderObject*, const Render
{
// Fire the start timeout if needed
fireAnimationEventsIfNeeded();
-
+
// If we have not yet started, we will not have a valid start time, so just start the animation if needed.
if (isNew() && m_animation->playState() == AnimPlayStatePlaying)
updateStateMachine(AnimationStateInputStartAnimation, -1);
@@ -185,7 +185,7 @@ void KeyframeAnimation::animate(CompositeAnimation*, RenderObject*, const Render
// through to the style blend so that we get the fromStyle.
if (waitingToStart() && m_animation->delay() > 0 && !m_animation->fillsBackwards())
return;
-
+
// If we have no keyframes, don't animate.
if (!m_keyframes.size()) {
updateStateMachine(AnimationStateInputEndAnimation, -1);
@@ -206,7 +206,7 @@ void KeyframeAnimation::animate(CompositeAnimation*, RenderObject*, const Render
const RenderStyle* toStyle = 0;
double progress = 0.0;
fetchIntervalEndpointsForProperty(*it, fromStyle, toStyle, progress);
-
+
bool needsAnim = CSSPropertyAnimation::blendProperties(this, *it, animatedStyle.get(), fromStyle, toStyle, progress);
if (!needsAnim)
// If we are running an accelerated animation, set a flag in the style
@@ -365,7 +365,7 @@ bool KeyframeAnimation::affectsProperty(CSSPropertyID property) const
void KeyframeAnimation::validateTransformFunctionList()
{
m_transformFunctionListValid = false;
-
+
if (m_keyframes.size() < 2 || !m_keyframes.containsProperty(CSSPropertyWebkitTransform))
return;
@@ -380,21 +380,21 @@ void KeyframeAnimation::validateTransformFunctionList()
break;
}
}
-
+
if (firstNonEmptyTransformKeyframeIndex == numKeyframes)
return;
-
+
const TransformOperations* firstVal = &m_keyframes[firstNonEmptyTransformKeyframeIndex].style()->transform();
-
+
// See if the keyframes are valid
for (size_t i = firstNonEmptyTransformKeyframeIndex + 1; i < numKeyframes; ++i) {
const KeyframeValue& currentKeyframe = m_keyframes[i];
const TransformOperations* val = &currentKeyframe.style()->transform();
-
+
// An emtpy transform list matches anything.
if (val->operations().isEmpty())
continue;
-
+
if (!firstVal->operationsMatch(*val))
return;
}
@@ -421,24 +421,24 @@ void KeyframeAnimation::checkForMatchingFilterFunctionLists()
break;
}
}
-
+
if (firstNonEmptyFilterKeyframeIndex == numKeyframes)
return;
-
+
const FilterOperations* firstVal = &m_keyframes[firstNonEmptyFilterKeyframeIndex].style()->filter();
-
+
for (size_t i = firstNonEmptyFilterKeyframeIndex + 1; i < numKeyframes; ++i) {
const KeyframeValue& currentKeyframe = m_keyframes[i];
const FilterOperations* val = &currentKeyframe.style()->filter();
-
+
// An emtpy filter list matches anything.
if (val->operations().isEmpty())
continue;
-
+
if (!firstVal->operationsMatch(*val))
return;
}
-
+
m_filterFunctionListsMatch = true;
}
@@ -447,12 +447,12 @@ double KeyframeAnimation::timeToNextService()
double t = AnimationBase::timeToNextService();
if (t != 0 || preActive())
return t;
-
- // A return value of 0 means we need service. But if we only have accelerated animations we
+
+ // A return value of 0 means we need service. But if we only have accelerated animations we
// only need service at the end of the transition
HashSet<CSSPropertyID>::const_iterator endProperties = m_keyframes.endProperties();
bool acceleratedPropertiesOnly = true;
-
+
for (HashSet<CSSPropertyID>::const_iterator it = m_keyframes.beginProperties(); it != endProperties; ++it) {
if (!CSSPropertyAnimation::animationOfPropertyIsAccelerated(*it) || !isAccelerated()) {
acceleratedPropertiesOnly = false;
« no previous file with comments | « Source/core/page/animation/KeyframeAnimation.h ('k') | Source/core/page/scrolling/ScrollingConstraints.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698