diff options
Diffstat (limited to 'content/browser/plugin_process_host.cc')
-rw-r--r-- | content/browser/plugin_process_host.cc | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/content/browser/plugin_process_host.cc b/content/browser/plugin_process_host.cc index 73b2f4a..c398d56 100644 --- a/content/browser/plugin_process_host.cc +++ b/content/browser/plugin_process_host.cc @@ -21,6 +21,7 @@ #include "base/string_util.h" #include "base/utf_string_conversions.h" #include "chrome/browser/browser_process.h" +#include "chrome/browser/net/resolve_proxy_msg_helper.h" #include "chrome/browser/net/url_request_tracking.h" #include "chrome/browser/plugin_download_helper.h" #include "chrome/browser/profiles/profile.h" @@ -95,8 +96,7 @@ void PluginProcessHost::OnMapNativeViewId(gfx::NativeViewId id, PluginProcessHost::PluginProcessHost() : BrowserChildProcessHost( PLUGIN_PROCESS, - PluginService::GetInstance()->resource_dispatcher_host()), - ALLOW_THIS_IN_INITIALIZER_LIST(resolve_proxy_msg_helper_(this, NULL)) + PluginService::GetInstance()->resource_dispatcher_host()) #if defined(OS_MACOSX) , plugin_cursor_visible_(true) #endif @@ -245,6 +245,8 @@ bool PluginProcessHost::Init(const webkit::npapi::WebPluginInfo& info, #endif cmd_line); + AddFilter(new ResolveProxyMsgHelper(NULL)); + return true; } @@ -260,8 +262,6 @@ bool PluginProcessHost::OnMessageReceived(const IPC::Message& msg) { IPC_MESSAGE_HANDLER(PluginProcessHostMsg_ChannelCreated, OnChannelCreated) IPC_MESSAGE_HANDLER(PluginProcessHostMsg_GetPluginFinderUrl, OnGetPluginFinderUrl) - IPC_MESSAGE_HANDLER_DELAY_REPLY(PluginProcessHostMsg_ResolveProxy, - OnResolveProxy) #if defined(OS_WIN) IPC_MESSAGE_HANDLER(PluginProcessHostMsg_PluginWindowDestroyed, OnPluginWindowDestroyed) @@ -330,19 +330,6 @@ void PluginProcessHost::OpenChannelToPlugin(Client* client) { RequestPluginChannel(client); } -void PluginProcessHost::OnResolveProxy(const GURL& url, - IPC::Message* reply_msg) { - resolve_proxy_msg_helper_.Start(url, reply_msg); -} - -void PluginProcessHost::OnResolveProxyCompleted(IPC::Message* reply_msg, - int result, - const std::string& proxy_list) { - PluginProcessHostMsg_ResolveProxy::WriteReplyParams( - reply_msg, result, proxy_list); - Send(reply_msg); -} - void PluginProcessHost::RequestPluginChannel(Client* client) { // We can't send any sync messages from the browser because it might lead to // a hang. However this async messages must be answered right away by the |