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

Unified Diff: content/renderer/compositor_bindings/web_animation_impl.cc

Issue 423373003: CC: Support fractional iteration count on compositor animations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Minor fixes Created 6 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
Index: content/renderer/compositor_bindings/web_animation_impl.cc
diff --git a/content/renderer/compositor_bindings/web_animation_impl.cc b/content/renderer/compositor_bindings/web_animation_impl.cc
index 6cec7ae034a315439fedaa9c3819fd179f76b106..7291570f9467abd46ee474376171d171b84d934d 100644
--- a/content/renderer/compositor_bindings/web_animation_impl.cc
+++ b/content/renderer/compositor_bindings/web_animation_impl.cc
@@ -77,7 +77,15 @@ blink::WebAnimation::TargetProperty WebAnimationImpl::targetProperty() const {
return static_cast<WebAnimationImpl::TargetProperty>(
animation_->target_property());
}
+#if WEB_ANIMATION_SUPPORTS_FRACTIONAL_ITERATIONS
+double WebAnimationImpl::iterations() const {
+ return animation_->iterations();
+}
+void WebAnimationImpl::setIterations(double n) {
+ animation_->set_iterations(n);
+}
+#else
int WebAnimationImpl::iterations() const {
return animation_->iterations();
}
@@ -85,7 +93,7 @@ int WebAnimationImpl::iterations() const {
void WebAnimationImpl::setIterations(int n) {
animation_->set_iterations(n);
}
-
+#endif
double WebAnimationImpl::startTime() const {
return (animation_->start_time() - base::TimeTicks()).InSecondsF();
}

Powered by Google App Engine
This is Rietveld 408576698