| Index: Source/web/ChromeClientImpl.cpp
|
| diff --git a/Source/web/ChromeClientImpl.cpp b/Source/web/ChromeClientImpl.cpp
|
| index ec7aa940bed3db6c6a5574f94764cef2b14bfbae..bd7a1ca6af1aadb4897fdcd917d07f1d53e41c89 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)
|
| {
|
| @@ -702,19 +705,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);
|
| }
|
| }
|
|
|