| Index: Source/web/WebRemoteFrameImpl.cpp
|
| diff --git a/Source/web/WebRemoteFrameImpl.cpp b/Source/web/WebRemoteFrameImpl.cpp
|
| index 1a026751f3e1b38bbcc738c23c6d432b10e51ab5..030c9941ebe56453c28da1196434ee071deb3cf0 100644
|
| --- a/Source/web/WebRemoteFrameImpl.cpp
|
| +++ b/Source/web/WebRemoteFrameImpl.cpp
|
| @@ -15,6 +15,7 @@
|
| #include "public/web/WebDocument.h"
|
| #include "public/web/WebPerformance.h"
|
| #include "public/web/WebRange.h"
|
| +#include "public/web/WebTreeScopeType.h"
|
| #include "web/RemoteBridgeFrameOwner.h"
|
| #include "web/WebViewImpl.h"
|
| #include <v8/include/v8.h>
|
| @@ -23,7 +24,17 @@ namespace blink {
|
|
|
| WebRemoteFrame* WebRemoteFrame::create(WebRemoteFrameClient* client)
|
| {
|
| - WebRemoteFrameImpl* frame = new WebRemoteFrameImpl(client);
|
| + return WebRemoteFrame::create(WebTreeScopeType::Document, client);
|
| +}
|
| +
|
| +WebRemoteFrame* WebRemoteFrame::create(WebTreeScopeType scope, WebRemoteFrameClient* client)
|
| +{
|
| + return WebRemoteFrameImpl::create(scope, client);
|
| +}
|
| +
|
| +WebRemoteFrame* WebRemoteFrameImpl::create(WebTreeScopeType scope, WebRemoteFrameClient* client)
|
| +{
|
| + WebRemoteFrameImpl* frame = new WebRemoteFrameImpl(scope, client);
|
| #if ENABLE(OILPAN)
|
| return frame;
|
| #else
|
| @@ -31,15 +42,6 @@ WebRemoteFrame* WebRemoteFrame::create(WebRemoteFrameClient* client)
|
| #endif
|
| }
|
|
|
| -WebRemoteFrameImpl::WebRemoteFrameImpl(WebRemoteFrameClient* client)
|
| - : m_frameClient(this)
|
| - , m_client(client)
|
| -#if ENABLE(OILPAN)
|
| - , m_selfKeepAlive(this)
|
| -#endif
|
| -{
|
| -}
|
| -
|
| WebRemoteFrameImpl::~WebRemoteFrameImpl()
|
| {
|
| }
|
| @@ -718,7 +720,12 @@ WebString WebRemoteFrameImpl::layerTreeAsText(bool showDebugInfo) const
|
|
|
| WebLocalFrame* WebRemoteFrameImpl::createLocalChild(const WebString& name, WebSandboxFlags sandboxFlags, WebFrameClient* client, WebFrame* previousSibling)
|
| {
|
| - WebLocalFrameImpl* child = toWebLocalFrameImpl(WebLocalFrame::create(client));
|
| + return createLocalChild(WebTreeScopeType::Document, name, sandboxFlags, client, previousSibling);
|
| +}
|
| +
|
| +WebLocalFrame* WebRemoteFrameImpl::createLocalChild(WebTreeScopeType scope, const WebString& name, WebSandboxFlags sandboxFlags, WebFrameClient* client, WebFrame* previousSibling)
|
| +{
|
| + WebLocalFrameImpl* child = toWebLocalFrameImpl(WebLocalFrame::create(scope, client));
|
| WillBeHeapHashMap<WebFrame*, OwnPtrWillBeMember<FrameOwner>>::AddResult result =
|
| m_ownersForChildren.add(child, RemoteBridgeFrameOwner::create(child, static_cast<SandboxFlags>(sandboxFlags)));
|
| insertAfter(child, previousSibling);
|
| @@ -733,6 +740,7 @@ WebLocalFrame* WebRemoteFrameImpl::createLocalChild(const WebString& name, WebSa
|
| return child;
|
| }
|
|
|
| +
|
| void WebRemoteFrameImpl::initializeCoreFrame(FrameHost* host, FrameOwner* owner, const AtomicString& name)
|
| {
|
| setCoreFrame(RemoteFrame::create(&m_frameClient, host, owner));
|
| @@ -742,7 +750,12 @@ void WebRemoteFrameImpl::initializeCoreFrame(FrameHost* host, FrameOwner* owner,
|
|
|
| WebRemoteFrame* WebRemoteFrameImpl::createRemoteChild(const WebString& name, WebSandboxFlags sandboxFlags, WebRemoteFrameClient* client)
|
| {
|
| - WebRemoteFrameImpl* child = toWebRemoteFrameImpl(WebRemoteFrame::create(client));
|
| + return createRemoteChild(WebTreeScopeType::Document, name, sandboxFlags, client);
|
| +}
|
| +
|
| +WebRemoteFrame* WebRemoteFrameImpl::createRemoteChild(WebTreeScopeType scope, const WebString& name, WebSandboxFlags sandboxFlags, WebRemoteFrameClient* client)
|
| +{
|
| + WebRemoteFrameImpl* child = toWebRemoteFrameImpl(WebRemoteFrame::create(scope, client));
|
| WillBeHeapHashMap<WebFrame*, OwnPtrWillBeMember<FrameOwner>>::AddResult result =
|
| m_ownersForChildren.add(child, RemoteBridgeFrameOwner::create(nullptr, static_cast<SandboxFlags>(sandboxFlags)));
|
| appendChild(child);
|
| @@ -810,4 +823,14 @@ void WebRemoteFrameImpl::didStopLoading()
|
| }
|
| }
|
|
|
| +WebRemoteFrameImpl::WebRemoteFrameImpl(WebTreeScopeType scope, WebRemoteFrameClient* client)
|
| + : WebRemoteFrame(scope)
|
| + , m_frameClient(this)
|
| + , m_client(client)
|
| +#if ENABLE(OILPAN)
|
| + , m_selfKeepAlive(this)
|
| +#endif
|
| +{
|
| +}
|
| +
|
| } // namespace blink
|
|
|