Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(463)

Unified Diff: content/browser/web_contents/web_contents_impl.cc

Issue 10978028: Propagate storage partition id and persistence to the browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/web_contents/web_contents_impl.cc
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index a92e5d3dfa517a5a071f2e9b82f35c07adf3dce2..00c5cf6aefa6fe023e7bb81d0fbd936ee2b9c783 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -736,8 +736,8 @@ bool WebContentsImpl::OnMessageReceived(RenderViewHost* render_view_host,
IPC_MESSAGE_HANDLER(ViewHostMsg_WebUISend, OnWebUISend)
IPC_MESSAGE_HANDLER(ViewHostMsg_RequestPpapiBrokerPermission,
OnRequestPpapiBrokerPermission)
- IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_NavigateGuest,
- OnBrowserPluginNavigateGuest)
+ IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_CreateGuest,
+ OnBrowserPluginCreateGuest)
IPC_MESSAGE_UNHANDLED(handled = false)
IPC_END_MESSAGE_MAP_EX()
message_source_ = NULL;
@@ -2364,27 +2364,26 @@ void WebContentsImpl::OnPpapiBrokerPermissionResult(int request_id,
result));
}
-void WebContentsImpl::OnBrowserPluginNavigateGuest(int instance_id,
- int64 frame_id,
- const std::string& src,
- const gfx::Size& size) {
- // This is the first 'navigate' to a browser plugin, before WebContents has/is
- // an 'Embedder'; subsequent navigate messages for this WebContents will
- // be handled by the BrowserPluginEmbedderHelper of the embedder itself (this
- // also means any message from browser plugin renderer prior to NavigateGuest
- // which is not NavigateGuest will be ignored). Therefore
- // |browser_plugin_embedder_| should not be set.
+void WebContentsImpl::OnBrowserPluginCreateGuest(
+ int instance_id,
+ int64 frame_id,
+ const std::string& storage_partition_id,
+ bool persist_storage) {
+ // This creates a BrowserPluginEmbedder, which handles all the BrowserPlugin
+ // specific messages for this WebContents (through its
+ // BrowserPluginEmbedderHelper). This means that any message from browser
+ // plugin renderer prior to CreateGuest will be ignored.
// For more info, see comment above classes BrowserPluginEmbedder and
// BrowserPluginGuest.
CHECK(!browser_plugin_embedder_.get());
browser_plugin_embedder_.reset(
content::BrowserPluginEmbedder::Create(this, GetRenderViewHost()));
- browser_plugin_embedder_->NavigateGuest(GetRenderViewHost(),
- instance_id,
- frame_id,
- src,
- size);
+ browser_plugin_embedder_->CreateGuest(GetRenderViewHost(),
+ instance_id,
+ frame_id,
+ std::string(),
+ false);
}
// Notifies the RenderWidgetHost instance about the fact that the page is

Powered by Google App Engine
This is Rietveld 408576698