| Index: Source/web/ChromeClientImpl.cpp
|
| diff --git a/Source/web/ChromeClientImpl.cpp b/Source/web/ChromeClientImpl.cpp
|
| index 98377cec588585c34a4b2762d7e0ef5df5921c5c..8200bb4b80a3065bb92f10d277db21511c119511 100644
|
| --- a/Source/web/ChromeClientImpl.cpp
|
| +++ b/Source/web/ChromeClientImpl.cpp
|
| @@ -34,6 +34,7 @@
|
|
|
| #include "bindings/core/v8/ScriptController.h"
|
| #include "core/HTMLNames.h"
|
| +#include "core/animation/AnimationTimeline.h"
|
| #include "core/dom/AXObjectCache.h"
|
| #include "core/dom/Document.h"
|
| #include "core/dom/Fullscreen.h"
|
| @@ -107,6 +108,8 @@
|
|
|
| namespace blink {
|
|
|
| +class WebCompositorAnimationTimeline;
|
| +
|
| // Converts a AXObjectCache::AXNotification to a WebAXEvent
|
| static WebAXEvent toWebAXEvent(AXObjectCache::AXNotification notification)
|
| {
|
| @@ -691,19 +694,24 @@ GraphicsLayerFactory* ChromeClientImpl::graphicsLayerFactory() const
|
|
|
| void ChromeClientImpl::attachRootGraphicsLayer(GraphicsLayer* rootLayer, LocalFrame* localRoot)
|
| {
|
| + WebCompositorAnimationTimeline* compositorTimeline = rootLayer && localRoot->document() ? localRoot->document()->timeline().compositorTimeline() : nullptr;
|
| +
|
| // FIXME: For top-level frames we still use the WebView as a WebWidget. This special
|
| // case will be removed when top-level frames get WebFrameWidgets.
|
| if (localRoot->isMainFrame()) {
|
| + m_webView->setCompositorAnimationTimeline(compositorTimeline);
|
| m_webView->setRootGraphicsLayer(rootLayer);
|
| } else {
|
| WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(localRoot);
|
| // FIXME: The following conditional is only needed for staging until the Chromium patch
|
| // lands that instantiates a WebFrameWidget.
|
| if (!webFrame->frameWidget()) {
|
| + m_webView->setCompositorAnimationTimeline(compositorTimeline);
|
| m_webView->setRootGraphicsLayer(rootLayer);
|
| return;
|
| }
|
| ASSERT(webFrame && webFrame->frameWidget());
|
| + webFrame->frameWidget()->setCompositorAnimationTimeline(compositorTimeline);
|
| webFrame->frameWidget()->setRootGraphicsLayer(rootLayer);
|
| }
|
| }
|
|
|