summaryrefslogtreecommitdiffstats
path: root/content/renderer
diff options
context:
space:
mode:
authordcheng@chromium.org <dcheng@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-04 15:50:22 +0000
committerdcheng@chromium.org <dcheng@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-04 15:50:22 +0000
commit35b2a970849f3e6daf1f6eccc42332d8bec6e6f3 (patch)
tree811894cba057d8dd69c6ad06b14c5c546e4291a2 /content/renderer
parentae195da1e844baf60ecff09543dfc541c2b1dce1 (diff)
downloadchromium_src-35b2a970849f3e6daf1f6eccc42332d8bec6e6f3.zip
chromium_src-35b2a970849f3e6daf1f6eccc42332d8bec6e6f3.tar.gz
chromium_src-35b2a970849f3e6daf1f6eccc42332d8bec6e6f3.tar.bz2
Conversion of content_shell target to use WebLocalFrame.
Fairly straightforward, as the locations where I had to add conversions should only ever expect to be called in the context of a local frame. BUG=346764 Review URL: https://codereview.chromium.org/222973003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261764 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer')
-rw-r--r--content/renderer/accessibility/renderer_accessibility_complete.cc2
-rw-r--r--content/renderer/accessibility/renderer_accessibility_complete.h2
-rw-r--r--content/renderer/accessibility/renderer_accessibility_focus_only.cc3
-rw-r--r--content/renderer/accessibility/renderer_accessibility_focus_only.h2
-rw-r--r--content/renderer/media/crypto/pepper_cdm_wrapper_impl.cc2
-rw-r--r--content/renderer/media/crypto/pepper_cdm_wrapper_impl.h5
-rw-r--r--content/renderer/media/webcontentdecryptionmodule_impl.cc2
-rw-r--r--content/renderer/media/webcontentdecryptionmodule_impl.h5
-rw-r--r--content/renderer/media/webmediaplayer_impl.cc2
-rw-r--r--content/renderer/media/webmediaplayer_impl.h14
-rw-r--r--content/renderer/pepper/resource_converter.cc2
-rw-r--r--content/renderer/render_frame_impl.cc127
-rw-r--r--content/renderer/render_frame_impl.h150
-rw-r--r--content/renderer/render_view_impl.cc156
-rw-r--r--content/renderer/render_view_impl.h136
-rw-r--r--content/renderer/web_ui_mojo.cc9
-rw-r--r--content/renderer/web_ui_mojo.h2
17 files changed, 313 insertions, 308 deletions
diff --git a/content/renderer/accessibility/renderer_accessibility_complete.cc b/content/renderer/accessibility/renderer_accessibility_complete.cc
index cd17e24..e5dd980 100644
--- a/content/renderer/accessibility/renderer_accessibility_complete.cc
+++ b/content/renderer/accessibility/renderer_accessibility_complete.cc
@@ -92,7 +92,7 @@ void RendererAccessibilityComplete::FocusedNodeChanged(const WebNode& node) {
}
}
-void RendererAccessibilityComplete::DidFinishLoad(blink::WebFrame* frame) {
+void RendererAccessibilityComplete::DidFinishLoad(blink::WebLocalFrame* frame) {
const WebDocument& document = GetMainDocument();
if (document.isNull())
return;
diff --git a/content/renderer/accessibility/renderer_accessibility_complete.h b/content/renderer/accessibility/renderer_accessibility_complete.h
index 16eeeae..227c72a 100644
--- a/content/renderer/accessibility/renderer_accessibility_complete.h
+++ b/content/renderer/accessibility/renderer_accessibility_complete.h
@@ -43,7 +43,7 @@ class CONTENT_EXPORT RendererAccessibilityComplete
// RenderView::Observer implementation.
virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
virtual void FocusedNodeChanged(const blink::WebNode& node) OVERRIDE;
- virtual void DidFinishLoad(blink::WebFrame* frame) OVERRIDE;
+ virtual void DidFinishLoad(blink::WebLocalFrame* frame) OVERRIDE;
// RendererAccessibility.
virtual void HandleWebAccessibilityEvent(
diff --git a/content/renderer/accessibility/renderer_accessibility_focus_only.cc b/content/renderer/accessibility/renderer_accessibility_focus_only.cc
index cebba6f..972916c 100644
--- a/content/renderer/accessibility/renderer_accessibility_focus_only.cc
+++ b/content/renderer/accessibility/renderer_accessibility_focus_only.cc
@@ -49,7 +49,8 @@ void RendererAccessibilityFocusOnly::FocusedNodeChanged(const WebNode& node) {
HandleFocusedNodeChanged(node, true);
}
-void RendererAccessibilityFocusOnly::DidFinishLoad(blink::WebFrame* frame) {
+void RendererAccessibilityFocusOnly::DidFinishLoad(
+ blink::WebLocalFrame* frame) {
WebView* view = render_view()->GetWebView();
if (view->focusedFrame() != frame)
return;
diff --git a/content/renderer/accessibility/renderer_accessibility_focus_only.h b/content/renderer/accessibility/renderer_accessibility_focus_only.h
index f5152fd..806cd4b 100644
--- a/content/renderer/accessibility/renderer_accessibility_focus_only.h
+++ b/content/renderer/accessibility/renderer_accessibility_focus_only.h
@@ -59,7 +59,7 @@ class RendererAccessibilityFocusOnly : public RendererAccessibility {
// RenderView::Observer implementation.
virtual void FocusedNodeChanged(const blink::WebNode& node) OVERRIDE;
- virtual void DidFinishLoad(blink::WebFrame* frame) OVERRIDE;
+ virtual void DidFinishLoad(blink::WebLocalFrame* frame) OVERRIDE;
private:
void HandleFocusedNodeChanged(const blink::WebNode& node,
diff --git a/content/renderer/media/crypto/pepper_cdm_wrapper_impl.cc b/content/renderer/media/crypto/pepper_cdm_wrapper_impl.cc
index 69059cd..73de599 100644
--- a/content/renderer/media/crypto/pepper_cdm_wrapper_impl.cc
+++ b/content/renderer/media/crypto/pepper_cdm_wrapper_impl.cc
@@ -21,7 +21,7 @@ void WebHelperPluginDeleter::operator()(blink::WebHelperPlugin* plugin) const {
}
scoped_ptr<PepperCdmWrapper> PepperCdmWrapperImpl::Create(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const std::string& pluginType) {
DCHECK(frame);
ScopedHelperPlugin helper_plugin(blink::WebHelperPlugin::create(
diff --git a/content/renderer/media/crypto/pepper_cdm_wrapper_impl.h b/content/renderer/media/crypto/pepper_cdm_wrapper_impl.h
index df037e8..75009a2c 100644
--- a/content/renderer/media/crypto/pepper_cdm_wrapper_impl.h
+++ b/content/renderer/media/crypto/pepper_cdm_wrapper_impl.h
@@ -13,9 +13,10 @@
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "content/renderer/media/crypto/pepper_cdm_wrapper.h"
+// TODO(dcheng): Temporary. Convert back to a forward declare.
+#include "third_party/WebKit/public/web/WebLocalFrame.h"
namespace blink {
-class WebFrame;
class WebHelperPlugin;
}
@@ -40,7 +41,7 @@ struct WebHelperPluginDeleter {
// blink:: objects.
class PepperCdmWrapperImpl : public PepperCdmWrapper {
public:
- static scoped_ptr<PepperCdmWrapper> Create(blink::WebFrame* frame,
+ static scoped_ptr<PepperCdmWrapper> Create(blink::WebLocalFrame* frame,
const std::string& pluginType);
virtual ~PepperCdmWrapperImpl();
diff --git a/content/renderer/media/webcontentdecryptionmodule_impl.cc b/content/renderer/media/webcontentdecryptionmodule_impl.cc
index bdb9f4e..e99859f 100644
--- a/content/renderer/media/webcontentdecryptionmodule_impl.cc
+++ b/content/renderer/media/webcontentdecryptionmodule_impl.cc
@@ -31,7 +31,7 @@ class WebFrame;
namespace content {
WebContentDecryptionModuleImpl* WebContentDecryptionModuleImpl::Create(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebSecurityOrigin& security_origin,
const base::string16& key_system) {
DCHECK(frame);
diff --git a/content/renderer/media/webcontentdecryptionmodule_impl.h b/content/renderer/media/webcontentdecryptionmodule_impl.h
index 38df1a0..ca9c218 100644
--- a/content/renderer/media/webcontentdecryptionmodule_impl.h
+++ b/content/renderer/media/webcontentdecryptionmodule_impl.h
@@ -11,9 +11,10 @@
#include "base/memory/scoped_ptr.h"
#include "base/strings/string16.h"
#include "third_party/WebKit/public/platform/WebContentDecryptionModule.h"
+// TODO(dcheng): Remove and convert back to a forward declare.
+#include "third_party/WebKit/public/web/WebLocalFrame.h"
namespace blink {
-class WebFrame;
class WebSecurityOrigin;
}
@@ -31,7 +32,7 @@ class WebContentDecryptionModuleImpl
: public blink::WebContentDecryptionModule {
public:
static WebContentDecryptionModuleImpl* Create(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebSecurityOrigin& security_origin,
const base::string16& key_system);
diff --git a/content/renderer/media/webmediaplayer_impl.cc b/content/renderer/media/webmediaplayer_impl.cc
index 813e103..451317e 100644
--- a/content/renderer/media/webmediaplayer_impl.cc
+++ b/content/renderer/media/webmediaplayer_impl.cc
@@ -140,7 +140,7 @@ static void LogMediaSourceError(const scoped_refptr<media::MediaLog>& media_log,
}
WebMediaPlayerImpl::WebMediaPlayerImpl(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebMediaPlayerClient* client,
base::WeakPtr<WebMediaPlayerDelegate> delegate,
const WebMediaPlayerParams& params)
diff --git a/content/renderer/media/webmediaplayer_impl.h b/content/renderer/media/webmediaplayer_impl.h
index 60d0138..d59b7c2a 100644
--- a/content/renderer/media/webmediaplayer_impl.h
+++ b/content/renderer/media/webmediaplayer_impl.h
@@ -27,13 +27,14 @@
#include "third_party/WebKit/public/platform/WebGraphicsContext3D.h"
#include "third_party/WebKit/public/platform/WebMediaPlayer.h"
#include "third_party/WebKit/public/platform/WebMediaPlayerClient.h"
+// TODO(dcheng): Convert back to forward declare.
+#include "third_party/WebKit/public/web/WebLocalFrame.h"
#include "url/gurl.h"
class RenderAudioSourceProvider;
namespace blink {
class WebContentDecryptionModule;
-class WebFrame;
}
namespace base {
@@ -68,11 +69,10 @@ class WebMediaPlayerImpl
public:
// Constructs a WebMediaPlayer implementation using Chromium's media stack.
// |delegate| may be null.
- WebMediaPlayerImpl(
- blink::WebFrame* frame,
- blink::WebMediaPlayerClient* client,
- base::WeakPtr<WebMediaPlayerDelegate> delegate,
- const WebMediaPlayerParams& params);
+ WebMediaPlayerImpl(blink::WebLocalFrame* frame,
+ blink::WebMediaPlayerClient* client,
+ base::WeakPtr<WebMediaPlayerDelegate> delegate,
+ const WebMediaPlayerParams& params);
virtual ~WebMediaPlayerImpl();
virtual void load(LoadType load_type,
@@ -238,7 +238,7 @@ class WebMediaPlayerImpl
// NULL immediately and reset.
void SetDecryptorReadyCB(const media::DecryptorReadyCB& decryptor_ready_cb);
- blink::WebFrame* frame_;
+ blink::WebLocalFrame* frame_;
// TODO(hclam): get rid of these members and read from the pipeline directly.
blink::WebMediaPlayer::NetworkState network_state_;
diff --git a/content/renderer/pepper/resource_converter.cc b/content/renderer/pepper/resource_converter.cc
index ac90364..d18e19e0 100644
--- a/content/renderer/pepper/resource_converter.cc
+++ b/content/renderer/pepper/resource_converter.cc
@@ -132,7 +132,7 @@ bool ResourceHostToDOMFileSystem(
blink::WebFileSystemType blink_type;
if (!FileApiFileSystemTypeToWebFileSystemType(type, &blink_type))
return false;
- blink::WebFrame* frame = blink::WebFrame::frameForContext(context);
+ blink::WebLocalFrame* frame = blink::WebLocalFrame::frameForContext(context);
blink::WebDOMFileSystem web_dom_file_system = blink::WebDOMFileSystem::create(
frame,
blink_type,
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index 3b80b81..b18c551 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -109,6 +109,7 @@ using blink::WebElement;
using blink::WebFrame;
using blink::WebHistoryItem;
using blink::WebHTTPBody;
+using blink::WebLocalFrame;
using blink::WebNavigationPolicy;
using blink::WebNavigationType;
using blink::WebNode;
@@ -330,7 +331,7 @@ RenderFrameImpl::~RenderFrameImpl() {
RenderThread::Get()->RemoveRoute(routing_id_);
}
-void RenderFrameImpl::SetWebFrame(blink::WebFrame* web_frame) {
+void RenderFrameImpl::SetWebFrame(blink::WebLocalFrame* web_frame) {
DCHECK(!frame_);
std::pair<FrameMap::iterator, bool> result = g_frame_map.Get().insert(
@@ -1156,10 +1157,9 @@ blink::WebPlugin* RenderFrameImpl::CreatePlugin(
#endif
}
-void RenderFrameImpl::LoadURLExternally(
- blink::WebFrame* frame,
- const blink::WebURLRequest& request,
- blink::WebNavigationPolicy policy) {
+void RenderFrameImpl::LoadURLExternally(blink::WebLocalFrame* frame,
+ const blink::WebURLRequest& request,
+ blink::WebNavigationPolicy policy) {
DCHECK(!frame_ || frame_ == frame);
loadURLExternally(frame, request, policy);
}
@@ -1176,7 +1176,7 @@ void RenderFrameImpl::OnChildFrameProcessGone() {
// blink::WebFrameClient implementation ----------------------------------------
blink::WebPlugin* RenderFrameImpl::createPlugin(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebPluginParams& params) {
DCHECK_EQ(frame_, frame);
blink::WebPlugin* plugin = NULL;
@@ -1209,7 +1209,7 @@ blink::WebPlugin* RenderFrameImpl::createPlugin(
}
blink::WebMediaPlayer* RenderFrameImpl::createMediaPlayer(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURL& url,
blink::WebMediaPlayerClient* client) {
DCHECK(!frame_ || frame_ == frame);
@@ -1221,7 +1221,7 @@ blink::WebMediaPlayer* RenderFrameImpl::createMediaPlayer(
blink::WebContentDecryptionModule*
RenderFrameImpl::createContentDecryptionModule(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebSecurityOrigin& security_origin,
const blink::WebString& key_system) {
DCHECK(!frame_ || frame_ == frame);
@@ -1230,7 +1230,7 @@ RenderFrameImpl::createContentDecryptionModule(
}
blink::WebApplicationCacheHost* RenderFrameImpl::createApplicationCacheHost(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebApplicationCacheHostClient* client) {
if (!frame || !frame->view())
return NULL;
@@ -1241,7 +1241,8 @@ blink::WebApplicationCacheHost* RenderFrameImpl::createApplicationCacheHost(
}
blink::WebWorkerPermissionClientProxy*
-RenderFrameImpl::createWorkerPermissionClientProxy(blink::WebFrame* frame) {
+RenderFrameImpl::createWorkerPermissionClientProxy(
+ blink::WebLocalFrame* frame) {
if (!frame || !frame->view())
return NULL;
DCHECK(!frame_ || frame_ == frame);
@@ -1249,13 +1250,13 @@ RenderFrameImpl::createWorkerPermissionClientProxy(blink::WebFrame* frame) {
this, frame);
}
-blink::WebCookieJar* RenderFrameImpl::cookieJar(blink::WebFrame* frame) {
+blink::WebCookieJar* RenderFrameImpl::cookieJar(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
return &cookie_jar_;
}
blink::WebServiceWorkerProvider* RenderFrameImpl::createServiceWorkerProvider(
- blink::WebFrame* frame) {
+ blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
// At this point we should have non-null data source.
DCHECK(frame->dataSource());
@@ -1269,13 +1270,13 @@ blink::WebServiceWorkerProvider* RenderFrameImpl::createServiceWorkerProvider(
ChildThread::current()->thread_safe_sender(), provider_id);
}
-void RenderFrameImpl::didAccessInitialDocument(blink::WebFrame* frame) {
+void RenderFrameImpl::didAccessInitialDocument(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
render_view_->didAccessInitialDocument(frame);
}
blink::WebFrame* RenderFrameImpl::createChildFrame(
- blink::WebFrame* parent,
+ blink::WebLocalFrame* parent,
const blink::WebString& name) {
// Synchronously notify the browser of a child frame creation to get the
// routing_id for the RenderFrame.
@@ -1300,14 +1301,14 @@ blink::WebFrame* RenderFrameImpl::createChildFrame(
RenderFrameImpl* child_render_frame = RenderFrameImpl::Create(
render_view_.get(), child_routing_id);
- blink::WebFrame* web_frame = WebFrame::create(child_render_frame);
+ blink::WebLocalFrame* web_frame = WebLocalFrame::create(child_render_frame);
parent->appendChild(web_frame);
child_render_frame->SetWebFrame(web_frame);
return web_frame;
}
-void RenderFrameImpl::didDisownOpener(blink::WebFrame* frame) {
+void RenderFrameImpl::didDisownOpener(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
render_view_->didDisownOpener(frame);
}
@@ -1367,7 +1368,7 @@ void RenderFrameImpl::willClose(blink::WebFrame* frame) {
render_view_->willClose(frame);
}
-void RenderFrameImpl::didChangeName(blink::WebFrame* frame,
+void RenderFrameImpl::didChangeName(blink::WebLocalFrame* frame,
const blink::WebString& name) {
DCHECK(!frame_ || frame_ == frame);
if (!render_view_->renderer_preferences_.report_frame_name_changes)
@@ -1381,7 +1382,7 @@ void RenderFrameImpl::didChangeName(blink::WebFrame* frame,
}
void RenderFrameImpl::didMatchCSS(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebVector<blink::WebString>& newly_matching_selectors,
const blink::WebVector<blink::WebString>& stopped_matching_selectors) {
DCHECK(!frame_ || frame_ == frame);
@@ -1445,7 +1446,7 @@ void RenderFrameImpl::didAddMessageToConsole(
source_name));
}
-void RenderFrameImpl::loadURLExternally(blink::WebFrame* frame,
+void RenderFrameImpl::loadURLExternally(blink::WebLocalFrame* frame,
const blink::WebURLRequest& request,
blink::WebNavigationPolicy policy) {
DCHECK(!frame_ || frame_ == frame);
@@ -1453,7 +1454,7 @@ void RenderFrameImpl::loadURLExternally(blink::WebFrame* frame,
}
void RenderFrameImpl::loadURLExternally(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURLRequest& request,
blink::WebNavigationPolicy policy,
const blink::WebString& suggested_name) {
@@ -1469,7 +1470,7 @@ void RenderFrameImpl::loadURLExternally(
}
blink::WebNavigationPolicy RenderFrameImpl::decidePolicyForNavigation(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebDataSource::ExtraData* extra_data,
const blink::WebURLRequest& request,
blink::WebNavigationType type,
@@ -1485,7 +1486,7 @@ blink::WebHistoryItem RenderFrameImpl::historyItemForNewChildFrame(
return render_view_->webview()->itemForNewChildFrame(frame);
}
-void RenderFrameImpl::willSendSubmitEvent(blink::WebFrame* frame,
+void RenderFrameImpl::willSendSubmitEvent(blink::WebLocalFrame* frame,
const blink::WebFormElement& form) {
DCHECK(!frame_ || frame_ == frame);
// Call back to RenderViewImpl for observers to be notified.
@@ -1493,7 +1494,7 @@ void RenderFrameImpl::willSendSubmitEvent(blink::WebFrame* frame,
render_view_->willSendSubmitEvent(frame, form);
}
-void RenderFrameImpl::willSubmitForm(blink::WebFrame* frame,
+void RenderFrameImpl::willSubmitForm(blink::WebLocalFrame* frame,
const blink::WebFormElement& form) {
DCHECK(!frame_ || frame_ == frame);
DocumentState* document_state =
@@ -1518,7 +1519,7 @@ void RenderFrameImpl::willSubmitForm(blink::WebFrame* frame,
render_view_->willSubmitForm(frame, form);
}
-void RenderFrameImpl::didCreateDataSource(blink::WebFrame* frame,
+void RenderFrameImpl::didCreateDataSource(blink::WebLocalFrame* frame,
blink::WebDataSource* datasource) {
DCHECK(!frame_ || frame_ == frame);
@@ -1538,7 +1539,7 @@ void RenderFrameImpl::didCreateDataSource(blink::WebFrame* frame,
network_provider.Pass());
}
-void RenderFrameImpl::didStartProvisionalLoad(blink::WebFrame* frame) {
+void RenderFrameImpl::didStartProvisionalLoad(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
WebDataSource* ds = frame->provisionalDataSource();
@@ -1593,7 +1594,7 @@ void RenderFrameImpl::didStartProvisionalLoad(blink::WebFrame* frame) {
}
void RenderFrameImpl::didReceiveServerRedirectForProvisionalLoad(
- blink::WebFrame* frame) {
+ blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
render_view_->webview()->removeChildrenForRedirect(frame);
if (frame->parent())
@@ -1616,9 +1617,8 @@ void RenderFrameImpl::didReceiveServerRedirectForProvisionalLoad(
}
}
-void RenderFrameImpl::didFailProvisionalLoad(
- blink::WebFrame* frame,
- const blink::WebURLError& error) {
+void RenderFrameImpl::didFailProvisionalLoad(blink::WebLocalFrame* frame,
+ const blink::WebURLError& error) {
DCHECK(!frame_ || frame_ == frame);
WebDataSource* ds = frame->provisionalDataSource();
DCHECK(ds);
@@ -1729,7 +1729,7 @@ void RenderFrameImpl::didCommitProvisionalLoad(
didCommitProvisionalLoad(frame, commit_type == blink::WebStandardCommit);
}
-void RenderFrameImpl::didCommitProvisionalLoad(blink::WebFrame* frame,
+void RenderFrameImpl::didCommitProvisionalLoad(blink::WebLocalFrame* frame,
bool is_new_navigation) {
DCHECK(!frame_ || frame_ == frame);
DocumentState* document_state =
@@ -1822,7 +1822,7 @@ void RenderFrameImpl::didCommitProvisionalLoad(blink::WebFrame* frame,
render_view_->UpdateEncoding(frame, frame->view()->pageEncoding().utf8());
}
-void RenderFrameImpl::didClearWindowObject(blink::WebFrame* frame,
+void RenderFrameImpl::didClearWindowObject(blink::WebLocalFrame* frame,
int world_id) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. Needed state:
@@ -1843,7 +1843,7 @@ void RenderFrameImpl::didClearWindowObject(blink::WebFrame* frame,
DidClearWindowObject(world_id));
}
-void RenderFrameImpl::didCreateDocumentElement(blink::WebFrame* frame) {
+void RenderFrameImpl::didCreateDocumentElement(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
// Notify the browser about non-blank documents loading in the top frame.
@@ -1862,7 +1862,7 @@ void RenderFrameImpl::didCreateDocumentElement(blink::WebFrame* frame) {
render_view_->didCreateDocumentElement(frame);
}
-void RenderFrameImpl::didReceiveTitle(blink::WebFrame* frame,
+void RenderFrameImpl::didReceiveTitle(blink::WebLocalFrame* frame,
const blink::WebString& title,
blink::WebTextDirection direction) {
DCHECK(!frame_ || frame_ == frame);
@@ -1870,14 +1870,14 @@ void RenderFrameImpl::didReceiveTitle(blink::WebFrame* frame,
render_view_->didReceiveTitle(frame, title, direction);
}
-void RenderFrameImpl::didChangeIcon(blink::WebFrame* frame,
+void RenderFrameImpl::didChangeIcon(blink::WebLocalFrame* frame,
blink::WebIconURL::Type icon_type) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Investigate wheather implementation should move here.
render_view_->didChangeIcon(frame, icon_type);
}
-void RenderFrameImpl::didFinishDocumentLoad(blink::WebFrame* frame) {
+void RenderFrameImpl::didFinishDocumentLoad(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
WebDataSource* ds = frame->dataSource();
DocumentState* document_state = DocumentState::FromDataSource(ds);
@@ -1895,14 +1895,14 @@ void RenderFrameImpl::didFinishDocumentLoad(blink::WebFrame* frame) {
render_view_->UpdateEncoding(frame, frame->view()->pageEncoding().utf8());
}
-void RenderFrameImpl::didHandleOnloadEvents(blink::WebFrame* frame) {
+void RenderFrameImpl::didHandleOnloadEvents(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. Needed state:
// * page_id_
render_view_->didHandleOnloadEvents(frame);
}
-void RenderFrameImpl::didFailLoad(blink::WebFrame* frame,
+void RenderFrameImpl::didFailLoad(blink::WebLocalFrame* frame,
const blink::WebURLError& error) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. No state needed.
@@ -1926,7 +1926,7 @@ void RenderFrameImpl::didFailLoad(blink::WebFrame* frame,
error_description));
}
-void RenderFrameImpl::didFinishLoad(blink::WebFrame* frame) {
+void RenderFrameImpl::didFinishLoad(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
WebDataSource* ds = frame->dataSource();
DocumentState* document_state = DocumentState::FromDataSource(ds);
@@ -1970,7 +1970,7 @@ void RenderFrameImpl::didNavigateWithinPage(blink::WebFrame* frame,
didCommitProvisionalLoad(frame, item, commit_type);
}
-void RenderFrameImpl::didNavigateWithinPage(blink::WebFrame* frame,
+void RenderFrameImpl::didNavigateWithinPage(blink::WebLocalFrame* frame,
bool is_new_navigation) {
DCHECK(!frame_ || frame_ == frame);
// If this was a reference fragment navigation that we initiated, then we
@@ -1990,7 +1990,7 @@ void RenderFrameImpl::didNavigateWithinPage(blink::WebFrame* frame,
didCommitProvisionalLoad(frame, is_new_navigation);
}
-void RenderFrameImpl::didUpdateCurrentHistoryItem(blink::WebFrame* frame) {
+void RenderFrameImpl::didUpdateCurrentHistoryItem(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. Needed methods:
// * StartNavStateSyncTimerIfNecessary
@@ -2067,7 +2067,7 @@ void RenderFrameImpl::clearContextMenu() {
}
void RenderFrameImpl::willRequestAfterPreconnect(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebURLRequest& request) {
DCHECK(!frame_ || frame_ == frame);
// FIXME(kohei): This will never be set.
@@ -2085,7 +2085,7 @@ void RenderFrameImpl::willRequestAfterPreconnect(
}
void RenderFrameImpl::willSendRequest(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
unsigned identifier,
blink::WebURLRequest& request,
const blink::WebURLResponse& redirect_response) {
@@ -2243,7 +2243,7 @@ void RenderFrameImpl::willSendRequest(
}
void RenderFrameImpl::didReceiveResponse(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
unsigned identifier,
const blink::WebURLResponse& response) {
DCHECK(!frame_ || frame_ == frame);
@@ -2289,7 +2289,7 @@ void RenderFrameImpl::didReceiveResponse(
internal_data->set_use_error_page(true);
}
-void RenderFrameImpl::didFinishResourceLoad(blink::WebFrame* frame,
+void RenderFrameImpl::didFinishResourceLoad(blink::WebLocalFrame* frame,
unsigned identifier) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. Needed state:
@@ -2300,7 +2300,7 @@ void RenderFrameImpl::didFinishResourceLoad(blink::WebFrame* frame,
}
void RenderFrameImpl::didLoadResourceFromMemoryCache(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURLRequest& request,
const blink::WebURLResponse& response) {
DCHECK(!frame_ || frame_ == frame);
@@ -2323,14 +2323,14 @@ void RenderFrameImpl::didLoadResourceFromMemoryCache(
ResourceType::FromTargetType(request.targetType())));
}
-void RenderFrameImpl::didDisplayInsecureContent(blink::WebFrame* frame) {
+void RenderFrameImpl::didDisplayInsecureContent(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
render_view_->Send(new ViewHostMsg_DidDisplayInsecureContent(
render_view_->GetRoutingID()));
}
void RenderFrameImpl::didRunInsecureContent(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebSecurityOrigin& origin,
const blink::WebURL& target) {
DCHECK(!frame_ || frame_ == frame);
@@ -2340,7 +2340,7 @@ void RenderFrameImpl::didRunInsecureContent(
target));
}
-void RenderFrameImpl::didAbortLoading(blink::WebFrame* frame) {
+void RenderFrameImpl::didAbortLoading(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
#if defined(ENABLE_PLUGINS)
if (frame != render_view_->webview()->mainFrame())
@@ -2350,7 +2350,7 @@ void RenderFrameImpl::didAbortLoading(blink::WebFrame* frame) {
#endif
}
-void RenderFrameImpl::didCreateScriptContext(blink::WebFrame* frame,
+void RenderFrameImpl::didCreateScriptContext(blink::WebLocalFrame* frame,
v8::Handle<v8::Context> context,
int extension_group,
int world_id) {
@@ -2359,7 +2359,7 @@ void RenderFrameImpl::didCreateScriptContext(blink::WebFrame* frame,
frame, context, extension_group, world_id);
}
-void RenderFrameImpl::willReleaseScriptContext(blink::WebFrame* frame,
+void RenderFrameImpl::willReleaseScriptContext(blink::WebLocalFrame* frame,
v8::Handle<v8::Context> context,
int world_id) {
DCHECK(!frame_ || frame_ == frame);
@@ -2369,12 +2369,13 @@ void RenderFrameImpl::willReleaseScriptContext(blink::WebFrame* frame,
WillReleaseScriptContext(context, world_id));
}
-void RenderFrameImpl::didFirstVisuallyNonEmptyLayout(blink::WebFrame* frame) {
+void RenderFrameImpl::didFirstVisuallyNonEmptyLayout(
+ blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
render_view_->didFirstVisuallyNonEmptyLayout(frame);
}
-void RenderFrameImpl::didChangeContentsSize(blink::WebFrame* frame,
+void RenderFrameImpl::didChangeContentsSize(blink::WebLocalFrame* frame,
const blink::WebSize& size) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. Needed state:
@@ -2383,14 +2384,14 @@ void RenderFrameImpl::didChangeContentsSize(blink::WebFrame* frame,
render_view_->didChangeContentsSize(frame, size);
}
-void RenderFrameImpl::didChangeScrollOffset(blink::WebFrame* frame) {
+void RenderFrameImpl::didChangeScrollOffset(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
// TODO(nasko): Move implementation here. Needed methods:
// * StartNavStateSyncTimerIfNecessary
render_view_->didChangeScrollOffset(frame);
}
-void RenderFrameImpl::willInsertBody(blink::WebFrame* frame) {
+void RenderFrameImpl::willInsertBody(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
if (!frame->parent()) {
render_view_->Send(new ViewHostMsg_WillInsertBody(
@@ -2420,7 +2421,7 @@ void RenderFrameImpl::reportFindInPageSelection(
}
void RenderFrameImpl::requestStorageQuota(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebStorageQuotaType type,
unsigned long long requested_size,
blink::WebStorageQuotaCallbacks callbacks) {
@@ -2445,7 +2446,7 @@ void RenderFrameImpl::willOpenSocketStream(
}
void RenderFrameImpl::willStartUsingPeerConnectionHandler(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebRTCPeerConnectionHandler* handler) {
DCHECK(!frame_ || frame_ == frame);
#if defined(ENABLE_WEBRTC)
@@ -2454,7 +2455,7 @@ void RenderFrameImpl::willStartUsingPeerConnectionHandler(
}
bool RenderFrameImpl::willCheckAndDispatchMessageEvent(
- blink::WebFrame* sourceFrame,
+ blink::WebLocalFrame* sourceFrame,
blink::WebFrame* targetFrame,
blink::WebSecurityOrigin targetOrigin,
blink::WebDOMMessageEvent event) {
@@ -2465,9 +2466,8 @@ bool RenderFrameImpl::willCheckAndDispatchMessageEvent(
sourceFrame, targetFrame, targetOrigin, event);
}
-blink::WebString RenderFrameImpl::userAgentOverride(
- blink::WebFrame* frame,
- const blink::WebURL& url) {
+blink::WebString RenderFrameImpl::userAgentOverride(blink::WebLocalFrame* frame,
+ const blink::WebURL& url) {
DCHECK(!frame_ || frame_ == frame);
if (!render_view_->webview() || !render_view_->webview()->mainFrame() ||
render_view_->renderer_preferences_.user_agent_override.empty()) {
@@ -2491,14 +2491,15 @@ blink::WebString RenderFrameImpl::userAgentOverride(
return blink::WebString();
}
-blink::WebString RenderFrameImpl::doNotTrackValue(blink::WebFrame* frame) {
+blink::WebString RenderFrameImpl::doNotTrackValue(blink::WebLocalFrame* frame) {
DCHECK(!frame_ || frame_ == frame);
if (render_view_->renderer_preferences_.enable_do_not_track)
return WebString::fromUTF8("1");
return WebString();
}
-bool RenderFrameImpl::allowWebGL(blink::WebFrame* frame, bool default_value) {
+bool RenderFrameImpl::allowWebGL(blink::WebLocalFrame* frame,
+ bool default_value) {
DCHECK(!frame_ || frame_ == frame);
if (!default_value)
return false;
@@ -2512,7 +2513,7 @@ bool RenderFrameImpl::allowWebGL(blink::WebFrame* frame, bool default_value) {
return !blocked;
}
-void RenderFrameImpl::didLoseWebGLContext(blink::WebFrame* frame,
+void RenderFrameImpl::didLoseWebGLContext(blink::WebLocalFrame* frame,
int arb_robustness_status_code) {
DCHECK(!frame_ || frame_ == frame);
render_view_->Send(new ViewHostMsg_DidLose3DContext(
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h
index b8654f8..6ccc95b 100644
--- a/content/renderer/render_frame_impl.h
+++ b/content/renderer/render_frame_impl.h
@@ -92,8 +92,9 @@ class CONTENT_EXPORT RenderFrameImpl
// Returns the RenderWidget associated with this frame.
RenderWidget* GetRenderWidget();
- // This is called right after creation with the WebFrame for this RenderFrame.
- void SetWebFrame(blink::WebFrame* web_frame);
+ // This is called right after creation with the WebLocalFrame for this
+ // RenderFrame.
+ void SetWebFrame(blink::WebLocalFrame* web_frame);
// Notification from RenderView.
virtual void OnStop();
@@ -182,43 +183,41 @@ class CONTENT_EXPORT RenderFrameImpl
blink::WebFrame* frame,
const WebPluginInfo& info,
const blink::WebPluginParams& params) OVERRIDE;
- virtual void LoadURLExternally(
- blink::WebFrame* frame,
- const blink::WebURLRequest& request,
- blink::WebNavigationPolicy policy) OVERRIDE;
+ virtual void LoadURLExternally(blink::WebLocalFrame* frame,
+ const blink::WebURLRequest& request,
+ blink::WebNavigationPolicy policy) OVERRIDE;
virtual void ExecuteJavaScript(const base::string16& javascript) OVERRIDE;
// blink::WebFrameClient implementation -------------------------------------
- virtual blink::WebPlugin* createPlugin(
- blink::WebFrame* frame,
- const blink::WebPluginParams& params);
+ virtual blink::WebPlugin* createPlugin(blink::WebLocalFrame* frame,
+ const blink::WebPluginParams& params);
virtual blink::WebMediaPlayer* createMediaPlayer(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURL& url,
blink::WebMediaPlayerClient* client);
virtual blink::WebContentDecryptionModule* createContentDecryptionModule(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebSecurityOrigin& security_origin,
const blink::WebString& key_system);
virtual blink::WebApplicationCacheHost* createApplicationCacheHost(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebApplicationCacheHostClient* client);
virtual blink::WebWorkerPermissionClientProxy*
- createWorkerPermissionClientProxy(blink::WebFrame* frame);
- virtual blink::WebCookieJar* cookieJar(blink::WebFrame* frame);
+ createWorkerPermissionClientProxy(blink::WebLocalFrame* frame);
+ virtual blink::WebCookieJar* cookieJar(blink::WebLocalFrame* frame);
virtual blink::WebServiceWorkerProvider* createServiceWorkerProvider(
- blink::WebFrame* frame);
- virtual void didAccessInitialDocument(blink::WebFrame* frame);
- virtual blink::WebFrame* createChildFrame(blink::WebFrame* parent,
- const blink::WebString& name);
- virtual void didDisownOpener(blink::WebFrame* frame);
+ blink::WebLocalFrame* frame);
+ virtual void didAccessInitialDocument(blink::WebLocalFrame* frame);
+ virtual blink::WebFrame* createChildFrame(blink::WebLocalFrame* parent,
+ const blink::WebString& name);
+ virtual void didDisownOpener(blink::WebLocalFrame* frame);
virtual void frameDetached(blink::WebFrame* frame);
virtual void frameFocused();
virtual void willClose(blink::WebFrame* frame);
- virtual void didChangeName(blink::WebFrame* frame,
+ virtual void didChangeName(blink::WebLocalFrame* frame,
const blink::WebString& name);
virtual void didMatchCSS(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebVector<blink::WebString>& newly_matching_selectors,
const blink::WebVector<blink::WebString>& stopped_matching_selectors);
virtual bool shouldReportDetailedMessageForSource(
@@ -227,17 +226,16 @@ class CONTENT_EXPORT RenderFrameImpl
const blink::WebString& source_name,
unsigned source_line,
const blink::WebString& stack_trace);
- virtual void loadURLExternally(blink::WebFrame* frame,
+ virtual void loadURLExternally(blink::WebLocalFrame* frame,
const blink::WebURLRequest& request,
blink::WebNavigationPolicy policy);
- virtual void loadURLExternally(
- blink::WebFrame* frame,
- const blink::WebURLRequest& request,
- blink::WebNavigationPolicy policy,
- const blink::WebString& suggested_name);
+ virtual void loadURLExternally(blink::WebLocalFrame* frame,
+ const blink::WebURLRequest& request,
+ blink::WebNavigationPolicy policy,
+ const blink::WebString& suggested_name);
// The WebDataSource::ExtraData* is assumed to be a DocumentState* subclass.
virtual blink::WebNavigationPolicy decidePolicyForNavigation(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebDataSource::ExtraData* extra_data,
const blink::WebURLRequest& request,
blink::WebNavigationType type,
@@ -245,13 +243,13 @@ class CONTENT_EXPORT RenderFrameImpl
bool is_redirect);
virtual blink::WebHistoryItem historyItemForNewChildFrame(
blink::WebFrame* frame);
- virtual void willSendSubmitEvent(blink::WebFrame* frame,
+ virtual void willSendSubmitEvent(blink::WebLocalFrame* frame,
const blink::WebFormElement& form);
- virtual void willSubmitForm(blink::WebFrame* frame,
+ virtual void willSubmitForm(blink::WebLocalFrame* frame,
const blink::WebFormElement& form);
- virtual void didCreateDataSource(blink::WebFrame* frame,
+ virtual void didCreateDataSource(blink::WebLocalFrame* frame,
blink::WebDataSource* datasource);
- virtual void didStartProvisionalLoad(blink::WebFrame* frame);
+ virtual void didStartProvisionalLoad(blink::WebLocalFrame* frame);
virtual void didReceiveServerRedirectForProvisionalLoad(
blink::WebFrame* frame);
virtual void didFailProvisionalLoad(
@@ -262,91 +260,87 @@ class CONTENT_EXPORT RenderFrameImpl
const blink::WebHistoryItem& item,
blink::WebHistoryCommitType commit_type);
// DEPRECATED
- virtual void didCommitProvisionalLoad(blink::WebFrame* frame,
+ virtual void didCommitProvisionalLoad(blink::WebLocalFrame* frame,
bool is_new_navigation);
- virtual void didClearWindowObject(blink::WebFrame* frame, int world_id);
- virtual void didCreateDocumentElement(blink::WebFrame* frame);
- virtual void didReceiveTitle(blink::WebFrame* frame,
+ virtual void didClearWindowObject(blink::WebLocalFrame* frame, int world_id);
+ virtual void didCreateDocumentElement(blink::WebLocalFrame* frame);
+ virtual void didReceiveTitle(blink::WebLocalFrame* frame,
const blink::WebString& title,
blink::WebTextDirection direction);
- virtual void didChangeIcon(blink::WebFrame* frame,
+ virtual void didChangeIcon(blink::WebLocalFrame* frame,
blink::WebIconURL::Type icon_type);
- virtual void didFinishDocumentLoad(blink::WebFrame* frame);
- virtual void didHandleOnloadEvents(blink::WebFrame* frame);
- virtual void didFailLoad(blink::WebFrame* frame,
+ virtual void didFinishDocumentLoad(blink::WebLocalFrame* frame);
+ virtual void didHandleOnloadEvents(blink::WebLocalFrame* frame);
+ virtual void didFailLoad(blink::WebLocalFrame* frame,
const blink::WebURLError& error);
virtual void didFinishLoad(blink::WebFrame* frame);
virtual void didNavigateWithinPage(blink::WebFrame* frame,
const blink::WebHistoryItem& item,
blink::WebHistoryCommitType commit_type);
// DEPRECATED
- virtual void didNavigateWithinPage(blink::WebFrame* frame,
+ virtual void didNavigateWithinPage(blink::WebLocalFrame* frame,
bool is_new_navigation);
- virtual void didUpdateCurrentHistoryItem(blink::WebFrame* frame);
+ virtual void didUpdateCurrentHistoryItem(blink::WebLocalFrame* frame);
virtual void didChangeSelection(bool is_empty_selection);
virtual void showContextMenu(const blink::WebContextMenuData& data);
virtual void clearContextMenu();
- virtual void willRequestAfterPreconnect(blink::WebFrame* frame,
+ virtual void willRequestAfterPreconnect(blink::WebLocalFrame* frame,
blink::WebURLRequest& request);
- virtual void willSendRequest(
- blink::WebFrame* frame,
- unsigned identifier,
- blink::WebURLRequest& request,
- const blink::WebURLResponse& redirect_response);
- virtual void didReceiveResponse(
- blink::WebFrame* frame,
- unsigned identifier,
- const blink::WebURLResponse& response);
- virtual void didFinishResourceLoad(blink::WebFrame* frame,
+ virtual void willSendRequest(blink::WebLocalFrame* frame,
+ unsigned identifier,
+ blink::WebURLRequest& request,
+ const blink::WebURLResponse& redirect_response);
+ virtual void didReceiveResponse(blink::WebLocalFrame* frame,
+ unsigned identifier,
+ const blink::WebURLResponse& response);
+ virtual void didFinishResourceLoad(blink::WebLocalFrame* frame,
unsigned identifier);
virtual void didLoadResourceFromMemoryCache(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURLRequest& request,
const blink::WebURLResponse& response);
- virtual void didDisplayInsecureContent(blink::WebFrame* frame);
- virtual void didRunInsecureContent(blink::WebFrame* frame,
+ virtual void didDisplayInsecureContent(blink::WebLocalFrame* frame);
+ virtual void didRunInsecureContent(blink::WebLocalFrame* frame,
const blink::WebSecurityOrigin& origin,
const blink::WebURL& target);
- virtual void didAbortLoading(blink::WebFrame* frame);
- virtual void didCreateScriptContext(blink::WebFrame* frame,
+ virtual void didAbortLoading(blink::WebLocalFrame* frame);
+ virtual void didCreateScriptContext(blink::WebLocalFrame* frame,
v8::Handle<v8::Context> context,
int extension_group,
int world_id);
- virtual void willReleaseScriptContext(blink::WebFrame* frame,
+ virtual void willReleaseScriptContext(blink::WebLocalFrame* frame,
v8::Handle<v8::Context> context,
int world_id);
- virtual void didFirstVisuallyNonEmptyLayout(blink::WebFrame* frame);
- virtual void didChangeContentsSize(blink::WebFrame* frame,
+ virtual void didFirstVisuallyNonEmptyLayout(blink::WebLocalFrame* frame);
+ virtual void didChangeContentsSize(blink::WebLocalFrame* frame,
const blink::WebSize& size);
- virtual void didChangeScrollOffset(blink::WebFrame* frame);
- virtual void willInsertBody(blink::WebFrame* frame);
+ virtual void didChangeScrollOffset(blink::WebLocalFrame* frame);
+ virtual void willInsertBody(blink::WebLocalFrame* frame);
virtual void reportFindInPageMatchCount(int request_id,
int count,
bool final_update);
virtual void reportFindInPageSelection(int request_id,
int active_match_ordinal,
const blink::WebRect& sel);
- virtual void requestStorageQuota(
- blink::WebFrame* frame,
- blink::WebStorageQuotaType type,
- unsigned long long requested_size,
- blink::WebStorageQuotaCallbacks callbacks);
+ virtual void requestStorageQuota(blink::WebLocalFrame* frame,
+ blink::WebStorageQuotaType type,
+ unsigned long long requested_size,
+ blink::WebStorageQuotaCallbacks callbacks);
virtual void willOpenSocketStream(
blink::WebSocketStreamHandle* handle);
virtual void willStartUsingPeerConnectionHandler(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
blink::WebRTCPeerConnectionHandler* handler);
virtual bool willCheckAndDispatchMessageEvent(
- blink::WebFrame* sourceFrame,
+ blink::WebLocalFrame* sourceFrame,
blink::WebFrame* targetFrame,
blink::WebSecurityOrigin targetOrigin,
blink::WebDOMMessageEvent event);
- virtual blink::WebString userAgentOverride(
- blink::WebFrame* frame,
- const blink::WebURL& url);
- virtual blink::WebString doNotTrackValue(blink::WebFrame* frame);
- virtual bool allowWebGL(blink::WebFrame* frame, bool default_value);
- virtual void didLoseWebGLContext(blink::WebFrame* frame,
+ virtual blink::WebString userAgentOverride(blink::WebLocalFrame* frame,
+ const blink::WebURL& url);
+ virtual blink::WebString doNotTrackValue(blink::WebLocalFrame* frame);
+ virtual bool allowWebGL(blink::WebLocalFrame* frame, bool default_value);
+ virtual void didLoseWebGLContext(blink::WebLocalFrame* frame,
int arb_robustness_status_code);
virtual void forwardInputEvent(const blink::WebInputEvent* event);
virtual void initializeChildFrame(const blink::WebRect& frame_rect,
@@ -451,8 +445,8 @@ class CONTENT_EXPORT RenderFrameImpl
const gfx::Range& selection_range,
const ContextMenuParams& params);
- // Stores the WebFrame we are associated with.
- blink::WebFrame* frame_;
+ // Stores the WebLocalFrame we are associated with.
+ blink::WebLocalFrame* frame_;
base::WeakPtr<RenderViewImpl> render_view_;
int routing_id_;
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index 9830d69..26d6b53 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -166,6 +166,7 @@
#include "third_party/WebKit/public/web/WebHistoryItem.h"
#include "third_party/WebKit/public/web/WebInputElement.h"
#include "third_party/WebKit/public/web/WebInputEvent.h"
+#include "third_party/WebKit/public/web/WebLocalFrame.h"
#include "third_party/WebKit/public/web/WebMediaPlayerAction.h"
#include "third_party/WebKit/public/web/WebNavigationPolicy.h"
#include "third_party/WebKit/public/web/WebNodeList.h"
@@ -271,6 +272,7 @@ using blink::WebIconURL;
using blink::WebImage;
using blink::WebInputElement;
using blink::WebInputEvent;
+using blink::WebLocalFrame;
using blink::WebMediaPlayer;
using blink::WebMediaPlayerAction;
using blink::WebMediaPlayerClient;
@@ -778,10 +780,10 @@ void RenderViewImpl::Initialize(RenderViewImplParams* params) {
main_render_frame_.reset(
RenderFrameImpl::Create(this, params->main_frame_routing_id));
- // The main frame WebFrame object is closed by
+ // The main frame WebLocalFrame object is closed by
// RenderFrameImpl::frameDetached().
- webview()->setMainFrame(WebFrame::create(main_render_frame_.get()));
- main_render_frame_->SetWebFrame(webview()->mainFrame());
+ webview()->setMainFrame(WebLocalFrame::create(main_render_frame_.get()));
+ main_render_frame_->SetWebFrame(webview()->mainFrame()->toWebLocalFrame());
if (switches::IsTouchDragDropEnabled())
webview()->settings()->setTouchDragDropEnabled(true);
@@ -1468,13 +1470,12 @@ void RenderViewImpl::OnWindowSnapshotCompleted(const int snapshot_id,
// blink::WebViewClient ------------------------------------------------------
-WebView* RenderViewImpl::createView(
- WebFrame* creator,
- const WebURLRequest& request,
- const WebWindowFeatures& features,
- const WebString& frame_name,
- WebNavigationPolicy policy,
- bool suppress_opener) {
+WebView* RenderViewImpl::createView(WebLocalFrame* creator,
+ const WebURLRequest& request,
+ const WebWindowFeatures& features,
+ const WebString& frame_name,
+ WebNavigationPolicy policy,
+ bool suppress_opener) {
ViewHostMsg_CreateWindow_Params params;
params.opener_id = routing_id_;
params.user_gesture = WebUserGestureIndicator::isProcessingUserGesture();
@@ -1602,7 +1603,7 @@ WebStorageNamespace* RenderViewImpl::createSessionStorageNamespace() {
return new WebStorageNamespaceImpl(session_storage_namespace_id_);
}
-void RenderViewImpl::printPage(WebFrame* frame) {
+void RenderViewImpl::printPage(WebLocalFrame* frame) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_,
PrintPage(frame, handling_input_event_));
}
@@ -1735,7 +1736,7 @@ bool RenderViewImpl::runFileChooser(
return ScheduleFileChooser(ipc_params, chooser_completion);
}
-void RenderViewImpl::runModalAlertDialog(WebFrame* frame,
+void RenderViewImpl::runModalAlertDialog(WebLocalFrame* frame,
const WebString& message) {
RunJavaScriptMessage(JAVASCRIPT_MESSAGE_TYPE_ALERT,
message,
@@ -1744,7 +1745,7 @@ void RenderViewImpl::runModalAlertDialog(WebFrame* frame,
NULL);
}
-bool RenderViewImpl::runModalConfirmDialog(WebFrame* frame,
+bool RenderViewImpl::runModalConfirmDialog(WebLocalFrame* frame,
const WebString& message) {
return RunJavaScriptMessage(JAVASCRIPT_MESSAGE_TYPE_CONFIRM,
message,
@@ -1753,7 +1754,7 @@ bool RenderViewImpl::runModalConfirmDialog(WebFrame* frame,
NULL);
}
-bool RenderViewImpl::runModalPromptDialog(WebFrame* frame,
+bool RenderViewImpl::runModalPromptDialog(WebLocalFrame* frame,
const WebString& message,
const WebString& default_value,
WebString* actual_value) {
@@ -1768,8 +1769,8 @@ bool RenderViewImpl::runModalPromptDialog(WebFrame* frame,
return ok;
}
-bool RenderViewImpl::runModalBeforeUnloadDialog(
- WebFrame* frame, const WebString& message) {
+bool RenderViewImpl::runModalBeforeUnloadDialog(WebLocalFrame* frame,
+ const WebString& message) {
bool is_reload = false;
WebDataSource* ds = frame->provisionalDataSource();
if (ds)
@@ -1777,8 +1778,9 @@ bool RenderViewImpl::runModalBeforeUnloadDialog(
return runModalBeforeUnloadDialog(frame, is_reload, message);
}
-bool RenderViewImpl::runModalBeforeUnloadDialog(
- WebFrame* frame, bool is_reload, const WebString& message) {
+bool RenderViewImpl::runModalBeforeUnloadDialog(WebLocalFrame* frame,
+ bool is_reload,
+ const WebString& message) {
// If we are swapping out, we have already run the beforeunload handler.
// TODO(creis): Fix OnSwapOut to clear the frame without running beforeunload
// at all, to avoid running it twice.
@@ -1906,7 +1908,7 @@ void RenderViewImpl::setKeyboardFocusURL(const WebURL& url) {
UpdateTargetURL(focus_url_, mouse_over_url_);
}
-void RenderViewImpl::startDragging(WebFrame* frame,
+void RenderViewImpl::startDragging(WebLocalFrame* frame,
const WebDragData& data,
WebDragOperationsMask mask,
const WebImage& image,
@@ -2149,14 +2151,16 @@ void RenderViewImpl::initializeLayerTreeView() {
// blink::WebFrameClient -----------------------------------------------------
WebMediaPlayer* RenderViewImpl::createMediaPlayer(
- WebFrame* frame, const blink::WebURL& url, WebMediaPlayerClient* client) {
+ WebLocalFrame* frame,
+ const blink::WebURL& url,
+ WebMediaPlayerClient* client) {
NOTREACHED();
return NULL;
}
blink::WebMediaPlayer* RenderViewImpl::CreateMediaPlayer(
RenderFrame* render_frame,
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURL& url,
blink::WebMediaPlayerClient* client) {
FOR_EACH_OBSERVER(
@@ -2180,14 +2184,14 @@ blink::WebMediaPlayer* RenderViewImpl::CreateMediaPlayer(
#endif // defined(OS_ANDROID)
}
-void RenderViewImpl::didAccessInitialDocument(WebFrame* frame) {
+void RenderViewImpl::didAccessInitialDocument(WebLocalFrame* frame) {
// Notify the browser process that it is no longer safe to show the pending
// URL of the main frame, since a URL spoof is now possible.
if (!frame->parent() && page_id_ == -1)
Send(new ViewHostMsg_DidAccessInitialDocument(routing_id_));
}
-void RenderViewImpl::didDisownOpener(blink::WebFrame* frame) {
+void RenderViewImpl::didDisownOpener(blink::WebLocalFrame* frame) {
// We only need to notify the browser if the active, top-level frame clears
// its opener. We can ignore cases where a swapped out frame clears its
// opener after hearing about it from the browser, and the browser does not
@@ -2212,7 +2216,7 @@ void RenderViewImpl::willClose(WebFrame* frame) {
}
void RenderViewImpl::didMatchCSS(
- WebFrame* frame,
+ WebLocalFrame* frame,
const WebVector<WebString>& newly_matching_selectors,
const WebVector<WebString>& stopped_matching_selectors) {
FOR_EACH_OBSERVER(
@@ -2254,19 +2258,20 @@ const std::string& RenderViewImpl::GetAcceptLanguages() const {
return renderer_preferences_.accept_languages;
}
-void RenderViewImpl::willSendSubmitEvent(blink::WebFrame* frame,
- const blink::WebFormElement& form) {
+void RenderViewImpl::willSendSubmitEvent(blink::WebLocalFrame* frame,
+ const blink::WebFormElement& form) {
FOR_EACH_OBSERVER(
RenderViewObserver, observers_, WillSendSubmitEvent(frame, form));
}
-void RenderViewImpl::willSubmitForm(WebFrame* frame,
+void RenderViewImpl::willSubmitForm(WebLocalFrame* frame,
const WebFormElement& form) {
FOR_EACH_OBSERVER(
RenderViewObserver, observers_, WillSubmitForm(frame, form));
}
-void RenderViewImpl::didCreateDataSource(WebFrame* frame, WebDataSource* ds) {
+void RenderViewImpl::didCreateDataSource(WebLocalFrame* frame,
+ WebDataSource* ds) {
bool content_initiated = !pending_navigation_params_.get();
// Make sure any previous redirect URLs end up in our new data source.
@@ -2444,10 +2449,9 @@ void RenderViewImpl::ProcessViewLayoutFlags(const CommandLine& command_line) {
}
// TODO(nasko): Remove this method once WebTestProxy in Blink is fixed.
-void RenderViewImpl::didStartProvisionalLoad(WebFrame* frame) {
-}
+void RenderViewImpl::didStartProvisionalLoad(WebLocalFrame* frame) {}
-void RenderViewImpl::didFailProvisionalLoad(WebFrame* frame,
+void RenderViewImpl::didFailProvisionalLoad(WebLocalFrame* frame,
const WebURLError& error) {
// Notify the browser that we failed a provisional load with an error.
//
@@ -2459,7 +2463,7 @@ void RenderViewImpl::didFailProvisionalLoad(WebFrame* frame,
RenderViewObserver, observers_, DidFailProvisionalLoad(frame, error));
}
-void RenderViewImpl::didCommitProvisionalLoad(WebFrame* frame,
+void RenderViewImpl::didCommitProvisionalLoad(WebLocalFrame* frame,
bool is_new_navigation) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_,
DidCommitProvisionalLoad(frame, is_new_navigation));
@@ -2476,7 +2480,7 @@ void RenderViewImpl::didCommitProvisionalLoad(WebFrame* frame,
}
}
-void RenderViewImpl::didClearWindowObject(WebFrame* frame, int world_id) {
+void RenderViewImpl::didClearWindowObject(WebLocalFrame* frame, int world_id) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_,
DidClearWindowObject(frame, world_id));
@@ -2499,12 +2503,13 @@ void RenderViewImpl::didClearWindowObject(WebFrame* frame, int world_id) {
MemoryBenchmarkingExtension::Install(frame);
}
-void RenderViewImpl::didCreateDocumentElement(WebFrame* frame) {
+void RenderViewImpl::didCreateDocumentElement(WebLocalFrame* frame) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_,
DidCreateDocumentElement(frame));
}
-void RenderViewImpl::didReceiveTitle(WebFrame* frame, const WebString& title,
+void RenderViewImpl::didReceiveTitle(WebLocalFrame* frame,
+ const WebString& title,
WebTextDirection direction) {
UpdateTitle(frame, title, direction);
@@ -2512,7 +2517,7 @@ void RenderViewImpl::didReceiveTitle(WebFrame* frame, const WebString& title,
UpdateEncoding(frame, frame->view()->pageEncoding().utf8());
}
-void RenderViewImpl::didChangeIcon(WebFrame* frame,
+void RenderViewImpl::didChangeIcon(WebLocalFrame* frame,
WebIconURL::Type icon_type) {
if (frame->parent())
return;
@@ -2531,52 +2536,53 @@ void RenderViewImpl::didChangeIcon(WebFrame* frame,
SendUpdateFaviconURL(urls);
}
-void RenderViewImpl::didFinishDocumentLoad(WebFrame* frame) {
+void RenderViewImpl::didFinishDocumentLoad(WebLocalFrame* frame) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_,
DidFinishDocumentLoad(frame));
}
-void RenderViewImpl::didHandleOnloadEvents(WebFrame* frame) {
+void RenderViewImpl::didHandleOnloadEvents(WebLocalFrame* frame) {
if (webview()->mainFrame() == frame) {
Send(new ViewHostMsg_DocumentOnLoadCompletedInMainFrame(routing_id_,
page_id_));
}
}
-void RenderViewImpl::didFailLoad(WebFrame* frame, const WebURLError& error) {
+void RenderViewImpl::didFailLoad(WebLocalFrame* frame,
+ const WebURLError& error) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_, DidFailLoad(frame, error));
}
-void RenderViewImpl::didFinishLoad(WebFrame* frame) {
+void RenderViewImpl::didFinishLoad(WebLocalFrame* frame) {
FOR_EACH_OBSERVER(RenderViewObserver, observers_, DidFinishLoad(frame));
}
-void RenderViewImpl::didNavigateWithinPage(
- WebFrame* frame,
- bool is_new_navigation) {
+void RenderViewImpl::didNavigateWithinPage(WebLocalFrame* frame,
+ bool is_new_navigation) {
// TODO(nasko): Forward calls to the main RenderFrameImpl until all
// callers of this method on RenderView are removed.
main_render_frame_->didNavigateWithinPage(frame, is_new_navigation);
}
-void RenderViewImpl::didUpdateCurrentHistoryItem(WebFrame* frame) {
+void RenderViewImpl::didUpdateCurrentHistoryItem(WebLocalFrame* frame) {
StartNavStateSyncTimerIfNecessary();
}
-void RenderViewImpl::willSendRequest(WebFrame* frame,
+void RenderViewImpl::willSendRequest(WebLocalFrame* frame,
unsigned identifier,
WebURLRequest& request,
const WebURLResponse& redirect_response) {
NOTREACHED();
}
-void RenderViewImpl::didReceiveResponse(
- WebFrame* frame, unsigned identifier, const WebURLResponse& response) {
+void RenderViewImpl::didReceiveResponse(WebLocalFrame* frame,
+ unsigned identifier,
+ const WebURLResponse& response) {
NOTREACHED();
}
-void RenderViewImpl::didFinishResourceLoad(
- WebFrame* frame, unsigned identifier) {
+void RenderViewImpl::didFinishResourceLoad(WebLocalFrame* frame,
+ unsigned identifier) {
InternalDocumentStateData* internal_data =
InternalDocumentStateData::FromDataSource(frame->dataSource());
if (!internal_data->use_error_page())
@@ -2600,28 +2606,30 @@ void RenderViewImpl::didFinishResourceLoad(
}
void RenderViewImpl::didLoadResourceFromMemoryCache(
- WebFrame* frame, const WebURLRequest& request,
+ WebLocalFrame* frame,
+ const WebURLRequest& request,
const WebURLResponse& response) {
NOTREACHED();
}
-void RenderViewImpl::didDisplayInsecureContent(WebFrame* frame) {
+void RenderViewImpl::didDisplayInsecureContent(WebLocalFrame* frame) {
NOTREACHED();
}
-void RenderViewImpl::didRunInsecureContent(
- WebFrame* frame, const WebSecurityOrigin& origin, const WebURL& target) {
+void RenderViewImpl::didRunInsecureContent(WebLocalFrame* frame,
+ const WebSecurityOrigin& origin,
+ const WebURL& target) {
NOTREACHED();
}
-void RenderViewImpl::didCreateScriptContext(WebFrame* frame,
+void RenderViewImpl::didCreateScriptContext(WebLocalFrame* frame,
v8::Handle<v8::Context> context,
int extension_group,
int world_id) {
NOTREACHED();
}
-void RenderViewImpl::willReleaseScriptContext(WebFrame* frame,
+void RenderViewImpl::willReleaseScriptContext(WebLocalFrame* frame,
v8::Handle<v8::Context> context,
int world_id) {
NOTREACHED();
@@ -2684,7 +2692,7 @@ bool RenderViewImpl::InitializeMediaStreamClient() {
#endif
}
-void RenderViewImpl::didChangeContentsSize(WebFrame* frame,
+void RenderViewImpl::didChangeContentsSize(WebLocalFrame* frame,
const WebSize& size) {
if (webview()->mainFrame() != frame)
return;
@@ -2725,7 +2733,7 @@ void RenderViewImpl::UpdateScrollState(WebFrame* frame) {
Send(new ViewHostMsg_DidChangeScrollOffset(routing_id_));
}
-void RenderViewImpl::didChangeScrollOffset(WebFrame* frame) {
+void RenderViewImpl::didChangeScrollOffset(WebLocalFrame* frame) {
StartNavStateSyncTimerIfNecessary();
if (webview()->mainFrame() == frame)
@@ -2735,11 +2743,11 @@ void RenderViewImpl::didChangeScrollOffset(WebFrame* frame) {
RenderViewObserver, observers_, DidChangeScrollOffset(frame));
}
-void RenderViewImpl::willInsertBody(blink::WebFrame* frame) {
+void RenderViewImpl::willInsertBody(blink::WebLocalFrame* frame) {
NOTREACHED();
}
-void RenderViewImpl::didFirstVisuallyNonEmptyLayout(WebFrame* frame) {
+void RenderViewImpl::didFirstVisuallyNonEmptyLayout(WebLocalFrame* frame) {
if (frame != webview()->mainFrame())
return;
@@ -2790,7 +2798,7 @@ void RenderViewImpl::reportFindInPageSelection(int request_id,
}
void RenderViewImpl::requestStorageQuota(
- WebFrame* frame,
+ WebLocalFrame* frame,
WebStorageQuotaType type,
unsigned long long requested_size,
blink::WebStorageQuotaCallbacks callbacks) {
@@ -2798,7 +2806,7 @@ void RenderViewImpl::requestStorageQuota(
}
bool RenderViewImpl::willCheckAndDispatchMessageEvent(
- blink::WebFrame* sourceFrame,
+ blink::WebLocalFrame* sourceFrame,
blink::WebFrame* targetFrame,
blink::WebSecurityOrigin target_origin,
blink::WebDOMMessageEvent event) {
@@ -2845,7 +2853,8 @@ void RenderViewImpl::willOpenSocketStream(
}
void RenderViewImpl::willStartUsingPeerConnectionHandler(
- blink::WebFrame* frame, blink::WebRTCPeerConnectionHandler* handler) {
+ blink::WebLocalFrame* frame,
+ blink::WebRTCPeerConnectionHandler* handler) {
NOTREACHED();
}
@@ -2853,26 +2862,24 @@ blink::WebString RenderViewImpl::acceptLanguages() {
return WebString::fromUTF8(renderer_preferences_.accept_languages);
}
-blink::WebString RenderViewImpl::userAgentOverride(
- blink::WebFrame* frame,
- const blink::WebURL& url) {
+blink::WebString RenderViewImpl::userAgentOverride(blink::WebLocalFrame* frame,
+ const blink::WebURL& url) {
NOTREACHED();
return blink::WebString();
}
-WebString RenderViewImpl::doNotTrackValue(WebFrame* frame) {
+WebString RenderViewImpl::doNotTrackValue(WebLocalFrame* frame) {
NOTREACHED();
return blink::WebString();
}
-bool RenderViewImpl::allowWebGL(WebFrame* frame, bool default_value) {
+bool RenderViewImpl::allowWebGL(WebLocalFrame* frame, bool default_value) {
NOTREACHED();
return false;
}
-void RenderViewImpl::didLoseWebGLContext(
- blink::WebFrame* frame,
- int arb_robustness_status_code) {
+void RenderViewImpl::didLoseWebGLContext(blink::WebLocalFrame* frame,
+ int arb_robustness_status_code) {
NOTREACHED();
}
@@ -2983,7 +2990,7 @@ blink::WebPageVisibilityState RenderViewImpl::GetVisibilityState() const {
return visibilityState();
}
-void RenderViewImpl::RunModalAlertDialog(blink::WebFrame* frame,
+void RenderViewImpl::RunModalAlertDialog(blink::WebLocalFrame* frame,
const blink::WebString& message) {
return runModalAlertDialog(frame, message);
}
@@ -3624,7 +3631,10 @@ void RenderViewImpl::OnGetSerializedHtmlDataForCurrentPageWithLocalLinks(
for (size_t i = 0; i < local_paths.size(); i++)
webstring_paths[i] = local_paths[i].AsUTF16Unsafe();
- WebPageSerializer::serialize(webview()->mainFrame(), true, this, weburl_links,
+ WebPageSerializer::serialize(webview()->mainFrame()->toWebLocalFrame(),
+ true,
+ this,
+ weburl_links,
webstring_paths,
local_directory_name.AsUTF16Unsafe());
}
@@ -4106,7 +4116,7 @@ void RenderViewImpl::OnImeConfirmComposition(
if (replacement_range.IsValid() && webview()) {
// Select the text in |replacement_range|, it will then be replaced by
// text added by the call to RenderWidget::OnImeConfirmComposition().
- if (WebFrame* frame = webview()->focusedFrame()) {
+ if (WebLocalFrame* frame = webview()->focusedFrame()->toWebLocalFrame()) {
WebRange webrange = WebRange::fromDocumentRange(
frame, replacement_range.start(), replacement_range.length());
if (!webrange.isNull())
diff --git a/content/renderer/render_view_impl.h b/content/renderer/render_view_impl.h
index a1aec93..b11af11 100644
--- a/content/renderer/render_view_impl.h
+++ b/content/renderer/render_view_impl.h
@@ -353,11 +353,10 @@ class CONTENT_EXPORT RenderViewImpl
// Temporary call until all this media code moves to RenderFrame.
// TODO(jam): remove me
- blink::WebMediaPlayer* CreateMediaPlayer(
- RenderFrame* render_frame,
- blink::WebFrame* frame,
- const blink::WebURL& url,
- blink::WebMediaPlayerClient* client);
+ blink::WebMediaPlayer* CreateMediaPlayer(RenderFrame* render_frame,
+ blink::WebLocalFrame* frame,
+ const blink::WebURL& url,
+ blink::WebMediaPlayerClient* client);
// Returns the length of the session history of this RenderView. Note that
// this only coincides with the actual length of the session history if this
// RenderView is the currently active RenderView of a WebContents.
@@ -413,19 +412,18 @@ class CONTENT_EXPORT RenderViewImpl
// blink::WebViewClient implementation --------------------------------------
- virtual blink::WebView* createView(
- blink::WebFrame* creator,
- const blink::WebURLRequest& request,
- const blink::WebWindowFeatures& features,
- const blink::WebString& frame_name,
- blink::WebNavigationPolicy policy,
- bool suppress_opener);
+ virtual blink::WebView* createView(blink::WebLocalFrame* creator,
+ const blink::WebURLRequest& request,
+ const blink::WebWindowFeatures& features,
+ const blink::WebString& frame_name,
+ blink::WebNavigationPolicy policy,
+ bool suppress_opener);
virtual blink::WebWidget* createPopupMenu(blink::WebPopupType popup_type);
virtual blink::WebExternalPopupMenu* createExternalPopupMenu(
const blink::WebPopupMenuInfo& popup_menu_info,
blink::WebExternalPopupMenuClient* popup_menu_client);
virtual blink::WebStorageNamespace* createSessionStorageNamespace();
- virtual void printPage(blink::WebFrame* frame);
+ virtual void printPage(blink::WebLocalFrame* frame);
virtual blink::WebNotificationPresenter* notificationPresenter();
virtual bool enumerateChosenDirectory(
const blink::WebString& path,
@@ -440,15 +438,15 @@ class CONTENT_EXPORT RenderViewImpl
virtual bool runFileChooser(
const blink::WebFileChooserParams& params,
blink::WebFileChooserCompletion* chooser_completion);
- virtual void runModalAlertDialog(blink::WebFrame* frame,
+ virtual void runModalAlertDialog(blink::WebLocalFrame* frame,
const blink::WebString& message);
- virtual bool runModalConfirmDialog(blink::WebFrame* frame,
+ virtual bool runModalConfirmDialog(blink::WebLocalFrame* frame,
const blink::WebString& message);
- virtual bool runModalPromptDialog(blink::WebFrame* frame,
+ virtual bool runModalPromptDialog(blink::WebLocalFrame* frame,
const blink::WebString& message,
const blink::WebString& default_value,
blink::WebString* actual_value);
- virtual bool runModalBeforeUnloadDialog(blink::WebFrame* frame,
+ virtual bool runModalBeforeUnloadDialog(blink::WebLocalFrame* frame,
bool is_reload,
const blink::WebString& message);
virtual void showValidationMessage(const blink::WebRect& anchor_in_root_view,
@@ -460,12 +458,12 @@ class CONTENT_EXPORT RenderViewImpl
const blink::WebRect& anchor_in_root_view) OVERRIDE;
// DEPRECATED
- virtual bool runModalBeforeUnloadDialog(blink::WebFrame* frame,
+ virtual bool runModalBeforeUnloadDialog(blink::WebLocalFrame* frame,
const blink::WebString& message);
virtual void setStatusText(const blink::WebString& text);
virtual void setMouseOverURL(const blink::WebURL& url);
virtual void setKeyboardFocusURL(const blink::WebURL& url);
- virtual void startDragging(blink::WebFrame* frame,
+ virtual void startDragging(blink::WebLocalFrame* frame,
const blink::WebDragData& data,
blink::WebDragOperationsMask mask,
const blink::WebImage& image,
@@ -521,72 +519,70 @@ class CONTENT_EXPORT RenderViewImpl
// blink::WebFrameClient implementation -------------------------------------
virtual blink::WebMediaPlayer* createMediaPlayer(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURL& url,
blink::WebMediaPlayerClient* client);
- virtual void didAccessInitialDocument(blink::WebFrame* frame);
- virtual void didDisownOpener(blink::WebFrame* frame);
+ virtual void didAccessInitialDocument(blink::WebLocalFrame* frame);
+ virtual void didDisownOpener(blink::WebLocalFrame* frame);
virtual void frameDetached(blink::WebFrame* frame);
virtual void willClose(blink::WebFrame* frame);
virtual void didMatchCSS(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebVector<blink::WebString>& newly_matching_selectors,
const blink::WebVector<blink::WebString>& stopped_matching_selectors);
- virtual void willSendSubmitEvent(blink::WebFrame* frame,
+ virtual void willSendSubmitEvent(blink::WebLocalFrame* frame,
const blink::WebFormElement& form);
- virtual void willSubmitForm(blink::WebFrame* frame,
+ virtual void willSubmitForm(blink::WebLocalFrame* frame,
const blink::WebFormElement& form);
- virtual void didCreateDataSource(blink::WebFrame* frame,
+ virtual void didCreateDataSource(blink::WebLocalFrame* frame,
blink::WebDataSource* datasource);
- virtual void didStartProvisionalLoad(blink::WebFrame* frame);
- virtual void didFailProvisionalLoad(blink::WebFrame* frame,
+ virtual void didStartProvisionalLoad(blink::WebLocalFrame* frame);
+ virtual void didFailProvisionalLoad(blink::WebLocalFrame* frame,
const blink::WebURLError& error);
- virtual void didCommitProvisionalLoad(blink::WebFrame* frame,
+ virtual void didCommitProvisionalLoad(blink::WebLocalFrame* frame,
bool is_new_navigation);
- virtual void didClearWindowObject(blink::WebFrame* frame, int world_id);
- virtual void didCreateDocumentElement(blink::WebFrame* frame);
- virtual void didReceiveTitle(blink::WebFrame* frame,
+ virtual void didClearWindowObject(blink::WebLocalFrame* frame, int world_id);
+ virtual void didCreateDocumentElement(blink::WebLocalFrame* frame);
+ virtual void didReceiveTitle(blink::WebLocalFrame* frame,
const blink::WebString& title,
blink::WebTextDirection direction);
- virtual void didChangeIcon(blink::WebFrame*,
- blink::WebIconURL::Type);
- virtual void didFinishDocumentLoad(blink::WebFrame* frame);
- virtual void didHandleOnloadEvents(blink::WebFrame* frame);
- virtual void didFailLoad(blink::WebFrame* frame,
+ virtual void didChangeIcon(blink::WebLocalFrame*, blink::WebIconURL::Type);
+ virtual void didFinishDocumentLoad(blink::WebLocalFrame* frame);
+ virtual void didHandleOnloadEvents(blink::WebLocalFrame* frame);
+ virtual void didFailLoad(blink::WebLocalFrame* frame,
const blink::WebURLError& error);
- virtual void didFinishLoad(blink::WebFrame* frame);
- virtual void didNavigateWithinPage(blink::WebFrame* frame,
+ virtual void didFinishLoad(blink::WebLocalFrame* frame);
+ virtual void didNavigateWithinPage(blink::WebLocalFrame* frame,
bool is_new_navigation);
- virtual void didUpdateCurrentHistoryItem(blink::WebFrame* frame);
- virtual void willSendRequest(blink::WebFrame* frame,
+ virtual void didUpdateCurrentHistoryItem(blink::WebLocalFrame* frame);
+ virtual void willSendRequest(blink::WebLocalFrame* frame,
unsigned identifier,
blink::WebURLRequest& request,
const blink::WebURLResponse& redirect_response);
- virtual void didReceiveResponse(blink::WebFrame* frame,
+ virtual void didReceiveResponse(blink::WebLocalFrame* frame,
unsigned identifier,
const blink::WebURLResponse& response);
- virtual void didFinishResourceLoad(blink::WebFrame* frame,
+ virtual void didFinishResourceLoad(blink::WebLocalFrame* frame,
unsigned identifier);
virtual void didLoadResourceFromMemoryCache(
- blink::WebFrame* frame,
+ blink::WebLocalFrame* frame,
const blink::WebURLRequest& request,
const blink::WebURLResponse&);
- virtual void didDisplayInsecureContent(blink::WebFrame* frame);
- virtual void didRunInsecureContent(
- blink::WebFrame* frame,
- const blink::WebSecurityOrigin& origin,
- const blink::WebURL& target);
- virtual void didCreateScriptContext(blink::WebFrame* frame,
+ virtual void didDisplayInsecureContent(blink::WebLocalFrame* frame);
+ virtual void didRunInsecureContent(blink::WebLocalFrame* frame,
+ const blink::WebSecurityOrigin& origin,
+ const blink::WebURL& target);
+ virtual void didCreateScriptContext(blink::WebLocalFrame* frame,
v8::Handle<v8::Context>,
int extension_group,
int world_id);
- virtual void willReleaseScriptContext(blink::WebFrame* frame,
+ virtual void willReleaseScriptContext(blink::WebLocalFrame* frame,
v8::Handle<v8::Context>,
int world_id);
- virtual void didChangeScrollOffset(blink::WebFrame* frame);
- virtual void willInsertBody(blink::WebFrame* frame);
- virtual void didFirstVisuallyNonEmptyLayout(blink::WebFrame*);
- virtual void didChangeContentsSize(blink::WebFrame* frame,
+ virtual void didChangeScrollOffset(blink::WebLocalFrame* frame);
+ virtual void willInsertBody(blink::WebLocalFrame* frame);
+ virtual void didFirstVisuallyNonEmptyLayout(blink::WebLocalFrame*);
+ virtual void didChangeContentsSize(blink::WebLocalFrame* frame,
const blink::WebSize& size);
virtual void reportFindInPageMatchCount(int request_id,
int count,
@@ -594,29 +590,27 @@ class CONTENT_EXPORT RenderViewImpl
virtual void reportFindInPageSelection(int request_id,
int active_match_ordinal,
const blink::WebRect& sel);
- virtual void requestStorageQuota(
- blink::WebFrame* frame,
- blink::WebStorageQuotaType type,
- unsigned long long requested_size,
- blink::WebStorageQuotaCallbacks callbacks);
+ virtual void requestStorageQuota(blink::WebLocalFrame* frame,
+ blink::WebStorageQuotaType type,
+ unsigned long long requested_size,
+ blink::WebStorageQuotaCallbacks callbacks);
virtual void willOpenSocketStream(
blink::WebSocketStreamHandle* handle);
- virtual void willStartUsingPeerConnectionHandler(blink::WebFrame* frame,
+ virtual void willStartUsingPeerConnectionHandler(
+ blink::WebLocalFrame* frame,
blink::WebRTCPeerConnectionHandler* handler);
virtual bool willCheckAndDispatchMessageEvent(
- blink::WebFrame* sourceFrame,
+ blink::WebLocalFrame* sourceFrame,
blink::WebFrame* targetFrame,
blink::WebSecurityOrigin targetOrigin,
blink::WebDOMMessageEvent event);
virtual blink::WebString acceptLanguages();
- virtual blink::WebString userAgentOverride(
- blink::WebFrame* frame,
- const blink::WebURL& url);
- virtual blink::WebString doNotTrackValue(blink::WebFrame* frame);
- virtual bool allowWebGL(blink::WebFrame* frame, bool default_value);
- virtual void didLoseWebGLContext(
- blink::WebFrame* frame,
- int arb_robustness_status_code);
+ virtual blink::WebString userAgentOverride(blink::WebLocalFrame* frame,
+ const blink::WebURL& url);
+ virtual blink::WebString doNotTrackValue(blink::WebLocalFrame* frame);
+ virtual bool allowWebGL(blink::WebLocalFrame* frame, bool default_value);
+ virtual void didLoseWebGLContext(blink::WebLocalFrame* frame,
+ int arb_robustness_status_code);
// blink::WebPageSerializerClient implementation ----------------------------
@@ -642,7 +636,7 @@ class CONTENT_EXPORT RenderViewImpl
virtual bool GetContentStateImmediately() const OVERRIDE;
virtual float GetFilteredTimePerFrame() const OVERRIDE;
virtual blink::WebPageVisibilityState GetVisibilityState() const OVERRIDE;
- virtual void RunModalAlertDialog(blink::WebFrame* frame,
+ virtual void RunModalAlertDialog(blink::WebLocalFrame* frame,
const blink::WebString& message) OVERRIDE;
virtual void DidStartLoading() OVERRIDE;
virtual void DidStopLoading() OVERRIDE;
diff --git a/content/renderer/web_ui_mojo.cc b/content/renderer/web_ui_mojo.cc
index 58f67a8..b972c97 100644
--- a/content/renderer/web_ui_mojo.cc
+++ b/content/renderer/web_ui_mojo.cc
@@ -65,7 +65,8 @@ WebUIMojo::~WebUIMojo() {
void WebUIMojo::CreateContextState() {
v8::HandleScope handle_scope(blink::mainThreadIsolate());
- blink::WebFrame* frame = render_view()->GetWebView()->mainFrame();
+ blink::WebFrame* frame =
+ render_view()->GetWebView()->mainFrame()->toWebLocalFrame();
v8::Handle<v8::Context> context = frame->mainWorldScriptContext();
gin::PerContextData* context_data = gin::PerContextData::From(context);
WebUIMojoContextStateData* data = new WebUIMojoContextStateData;
@@ -96,7 +97,8 @@ void WebUIMojo::SetHandleOnContextState(mojo::ScopedMessagePipeHandle handle) {
}
WebUIMojoContextState* WebUIMojo::GetContextState() {
- blink::WebFrame* frame = render_view()->GetWebView()->mainFrame();
+ blink::WebLocalFrame* frame =
+ render_view()->GetWebView()->mainFrame()->toWebLocalFrame();
v8::HandleScope handle_scope(blink::mainThreadIsolate());
v8::Handle<v8::Context> context = frame->mainWorldScriptContext();
gin::PerContextData* context_data = gin::PerContextData::From(context);
@@ -108,7 +110,8 @@ WebUIMojoContextState* WebUIMojo::GetContextState() {
return context_state ? context_state->state.get() : NULL;
}
-void WebUIMojo::DidClearWindowObject(blink::WebFrame* frame, int world_id) {
+void WebUIMojo::DidClearWindowObject(blink::WebLocalFrame* frame,
+ int world_id) {
if (frame != render_view()->GetWebView()->mainFrame())
return;
diff --git a/content/renderer/web_ui_mojo.h b/content/renderer/web_ui_mojo.h
index d9a7f00..504f737 100644
--- a/content/renderer/web_ui_mojo.h
+++ b/content/renderer/web_ui_mojo.h
@@ -65,7 +65,7 @@ class WebUIMojo
WebUIMojoContextState* GetContextState();
// RenderViewObserver overrides:
- virtual void DidClearWindowObject(blink::WebFrame* frame,
+ virtual void DidClearWindowObject(blink::WebLocalFrame* frame,
int world_id) OVERRIDE;
MainFrameObserver main_frame_observer_;