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

Unified Diff: content/renderer/render_view_impl.cc

Issue 10093011: Show a replacement plug-in for loading errors. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 8 years, 8 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
« no previous file with comments | « content/renderer/render_view_impl.h ('k') | content/shell/shell_content_renderer_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_view_impl.cc
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index a3696bd49a2157415683dcdc25ea070af35d9d08..e207b93ed462630faa9656aa4ca2e50b13a2dc63 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -2135,6 +2135,17 @@ WebPlugin* RenderViewImpl::createPlugin(WebFrame* frame,
return CreatePlugin(frame, info, params_to_use);
}
+WebPlugin* RenderViewImpl::createPluginReplacement(
+ WebFrame* frame,
+ const WebPluginParams& params) {
+ webkit::WebPluginInfo info;
+ std::string mime_type;
+ GetPluginInfo(params.url, frame->top()->document().url(),
+ params.mimeType.utf8(), &info, &mime_type);
+ return content::GetContentClient()->renderer()->CreatePluginReplacement(
+ this, info.path);
+}
+
WebSharedWorker* RenderViewImpl::createSharedWorker(
WebFrame* frame, const WebURL& url, const WebString& name,
unsigned long long document_id) {
@@ -3671,6 +3682,12 @@ webkit::npapi::WebPluginDelegate* RenderViewImpl::CreatePluginDelegate(
return new WebPluginDelegateProxy(mime_type, AsWeakPtr());
}
+WebKit::WebPlugin* RenderViewImpl::CreatePluginReplacement(
+ const FilePath& file_path) {
+ return content::GetContentClient()->renderer()->CreatePluginReplacement(
+ this, file_path);
+}
+
void RenderViewImpl::CreatedPluginWindow(gfx::PluginWindowHandle window) {
#if defined(USE_X11)
Send(new ViewHostMsg_CreatePluginContainer(routing_id(), window));
« no previous file with comments | « content/renderer/render_view_impl.h ('k') | content/shell/shell_content_renderer_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698