| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/ppapi_plugin/ppapi_thread.h" | 5 #include "content/ppapi_plugin/ppapi_thread.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/debug/crash_logging.h" | 10 #include "base/debug/crash_logging.h" |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 ppapi::proxy::PluginGlobals* globals = ppapi::proxy::PluginGlobals::Get(); | 93 ppapi::proxy::PluginGlobals* globals = ppapi::proxy::PluginGlobals::Get(); |
| 94 globals->set_plugin_proxy_delegate(this); | 94 globals->set_plugin_proxy_delegate(this); |
| 95 globals->set_command_line( | 95 globals->set_command_line( |
| 96 command_line.GetSwitchValueASCII(switches::kPpapiFlashArgs)); | 96 command_line.GetSwitchValueASCII(switches::kPpapiFlashArgs)); |
| 97 | 97 |
| 98 webkit_platform_support_.reset(new PpapiWebKitPlatformSupportImpl); | 98 webkit_platform_support_.reset(new PpapiWebKitPlatformSupportImpl); |
| 99 WebKit::initialize(webkit_platform_support_.get()); | 99 WebKit::initialize(webkit_platform_support_.get()); |
| 100 | 100 |
| 101 // Register interfaces that expect messages from the browser process. Please | 101 // Register interfaces that expect messages from the browser process. Please |
| 102 // note that only those InterfaceProxy-based ones require registration. | 102 // note that only those InterfaceProxy-based ones require registration. |
| 103 AddRoute(ppapi::API_ID_PPB_TCPSERVERSOCKET_PRIVATE, | |
| 104 &dispatcher_message_listener_); | |
| 105 AddRoute(ppapi::API_ID_PPB_TCPSOCKET, | 103 AddRoute(ppapi::API_ID_PPB_TCPSOCKET, |
| 106 &dispatcher_message_listener_); | 104 &dispatcher_message_listener_); |
| 107 AddRoute(ppapi::API_ID_PPB_TCPSOCKET_PRIVATE, | 105 AddRoute(ppapi::API_ID_PPB_TCPSOCKET_PRIVATE, |
| 108 &dispatcher_message_listener_); | 106 &dispatcher_message_listener_); |
| 109 AddRoute(ppapi::API_ID_PPB_UDPSOCKET_PRIVATE, | |
| 110 &dispatcher_message_listener_); | |
| 111 AddRoute(ppapi::API_ID_PPB_HOSTRESOLVER_PRIVATE, | 107 AddRoute(ppapi::API_ID_PPB_HOSTRESOLVER_PRIVATE, |
| 112 &dispatcher_message_listener_); | 108 &dispatcher_message_listener_); |
| 113 AddRoute(ppapi::API_ID_PPB_NETWORKMANAGER_PRIVATE, | 109 AddRoute(ppapi::API_ID_PPB_NETWORKMANAGER_PRIVATE, |
| 114 &dispatcher_message_listener_); | 110 &dispatcher_message_listener_); |
| 115 } | 111 } |
| 116 | 112 |
| 117 PpapiThread::~PpapiThread() { | 113 PpapiThread::~PpapiThread() { |
| 118 } | 114 } |
| 119 | 115 |
| 120 void PpapiThread::Shutdown() { | 116 void PpapiThread::Shutdown() { |
| (...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 507 histogram_name.str(), | 503 histogram_name.str(), |
| 508 1, | 504 1, |
| 509 LOAD_RESULT_MAX, | 505 LOAD_RESULT_MAX, |
| 510 LOAD_RESULT_MAX + 1, | 506 LOAD_RESULT_MAX + 1, |
| 511 base::HistogramBase::kUmaTargetedHistogramFlag); | 507 base::HistogramBase::kUmaTargetedHistogramFlag); |
| 512 | 508 |
| 513 histogram->Add(result); | 509 histogram->Add(result); |
| 514 } | 510 } |
| 515 | 511 |
| 516 } // namespace content | 512 } // namespace content |
| OLD | NEW |