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

Unified Diff: third_party/WebKit/Source/core/animation/CSSLengthInterpolationType.cpp

Issue 2697743002: Reduce strictness of length animation DCHECK (Closed)
Patch Set: _dcheckLengthApply Created 3 years, 10 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 | « third_party/WebKit/LayoutTests/animations/length-zero-percent-crash.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/animation/CSSLengthInterpolationType.cpp
diff --git a/third_party/WebKit/Source/core/animation/CSSLengthInterpolationType.cpp b/third_party/WebKit/Source/core/animation/CSSLengthInterpolationType.cpp
index 37311c6aacf52d319aca662c4677371bbda0e629..ac39982102a98e49bd7059718478efec12e50992 100644
--- a/third_party/WebKit/Source/core/animation/CSSLengthInterpolationType.cpp
+++ b/third_party/WebKit/Source/core/animation/CSSLengthInterpolationType.cpp
@@ -158,13 +158,12 @@ void CSSLengthInterpolationType::applyStandardPropertyValue(
StyleBuilder::applyProperty(cssProperty(), state,
*CSSValue::create(length, zoom));
DCHECK(LengthPropertyFunctions::getLength(cssProperty(), style, after));
- DCHECK_EQ(before.type(), after.type());
- if (before.isSpecified()) {
- const float kSlack = 0.1;
- float delta =
- floatValueForLength(after, 100) - floatValueForLength(before, 100);
- DCHECK_LT(std::abs(delta), kSlack);
- }
+ DCHECK(before.isSpecified());
+ DCHECK(after.isSpecified());
+ const float kSlack = 0.1;
+ float delta =
+ floatValueForLength(after, 100) - floatValueForLength(before, 100);
+ DCHECK_LT(std::abs(delta), kSlack);
#endif
return;
}
« no previous file with comments | « third_party/WebKit/LayoutTests/animations/length-zero-percent-crash.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698