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

Unified Diff: webkit/compositor_bindings/web_layer_tree_view_impl.cc

Issue 11783101: Make LayerTreeHost::animateLayers take a wall clock time in addition to a monotonic time (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix nits Created 7 years, 11 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 | « webkit/compositor_bindings/web_layer_tree_view_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/compositor_bindings/web_layer_tree_view_impl.cc
diff --git a/webkit/compositor_bindings/web_layer_tree_view_impl.cc b/webkit/compositor_bindings/web_layer_tree_view_impl.cc
index e42a3c7696331bf47a8da012a6b1f72fab3371ae..dec9c015414a7eb62bca02c926d0113a4ebca6be 100644
--- a/webkit/compositor_bindings/web_layer_tree_view_impl.cc
+++ b/webkit/compositor_bindings/web_layer_tree_view_impl.cc
@@ -151,10 +151,18 @@ void WebLayerTreeViewImpl::composite()
m_layerTreeHost->composite();
}
+// TODO(ajuma): Remove this after WebKit bug 106594 (which switches to using the 2-argument version) lands.
void WebLayerTreeViewImpl::updateAnimations(double frameBeginTimeSeconds)
{
base::TimeTicks frameBeginTime = base::TimeTicks::FromInternalValue(frameBeginTimeSeconds * base::Time::kMicrosecondsPerSecond);
- m_layerTreeHost->updateAnimations(frameBeginTime);
+ m_layerTreeHost->updateAnimations(frameBeginTime, base::Time::Now());
+}
+
+void WebLayerTreeViewImpl::updateAnimations(double monotonicFrameBeginTimeSeconds, double wallClockFrameBeginTimeSeconds)
+{
+ base::TimeTicks monotonicFrameBeginTime = base::TimeTicks::FromInternalValue(monotonicFrameBeginTimeSeconds * base::Time::kMicrosecondsPerSecond);
+ base::Time wallClockFrameBeginTime = base::Time::FromDoubleT(wallClockFrameBeginTimeSeconds);
+ m_layerTreeHost->updateAnimations(monotonicFrameBeginTime, wallClockFrameBeginTime);
}
void WebLayerTreeViewImpl::didStopFlinging()
« no previous file with comments | « webkit/compositor_bindings/web_layer_tree_view_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698