| Index: Source/core/frame/RemoteFrame.cpp
|
| diff --git a/Source/core/frame/RemoteFrame.cpp b/Source/core/frame/RemoteFrame.cpp
|
| index cde4b2c8623e530e1db70262c23eed7c597734f4..909c47d45595e38338cbd3be967d22e98b651118 100644
|
| --- a/Source/core/frame/RemoteFrame.cpp
|
| +++ b/Source/core/frame/RemoteFrame.cpp
|
| @@ -10,7 +10,11 @@
|
| #include "core/frame/RemoteFrameClient.h"
|
| #include "core/frame/RemoteFrameView.h"
|
| #include "core/html/HTMLFrameOwnerElement.h"
|
| +#include "core/rendering/RenderLayer.h"
|
| +#include "core/rendering/RenderPart.h"
|
| +#include "platform/graphics/GraphicsLayer.h"
|
| #include "platform/weborigin/SecurityPolicy.h"
|
| +#include "public/platform/WebLayer.h"
|
|
|
| namespace blink {
|
|
|
| @@ -70,6 +74,13 @@ RemoteSecurityContext* RemoteFrame::securityContext() const
|
| return m_securityContext.get();
|
| }
|
|
|
| +void RemoteFrame::disconnectOwnerElement()
|
| +{
|
| + if (owner() && owner()->isLocal())
|
| + setRemotePlatformLayer(nullptr);
|
| + Frame::disconnectOwnerElement();
|
| +}
|
| +
|
| void RemoteFrame::forwardInputEvent(Event* event)
|
| {
|
| remoteFrameClient()->forwardInputEvent(event);
|
| @@ -99,4 +110,18 @@ RemoteFrameClient* RemoteFrame::remoteFrameClient() const
|
| return static_cast<RemoteFrameClient*>(client());
|
| }
|
|
|
| +void RemoteFrame::setRemotePlatformLayer(WebLayer* layer)
|
| +{
|
| + if (m_remotePlatformLayer)
|
| + GraphicsLayer::unregisterContentsLayer(m_remotePlatformLayer);
|
| + m_remotePlatformLayer = layer;
|
| + if (m_remotePlatformLayer)
|
| + GraphicsLayer::registerContentsLayer(layer);
|
| +
|
| + ASSERT(owner());
|
| + toHTMLFrameOwnerElement(owner())->setNeedsCompositingUpdate();
|
| + if (RenderPart* renderer = ownerRenderer())
|
| + renderer->layer()->updateSelfPaintingLayer();
|
| +}
|
| +
|
| } // namespace blink
|
|
|