| 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 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 ppapi::proxy::PluginGlobals* globals = ppapi::proxy::PluginGlobals::Get(); | 94 ppapi::proxy::PluginGlobals* globals = ppapi::proxy::PluginGlobals::Get(); |
| 95 globals->set_plugin_proxy_delegate(this); | 95 globals->set_plugin_proxy_delegate(this); |
| 96 globals->set_command_line( | 96 globals->set_command_line( |
| 97 command_line.GetSwitchValueASCII(switches::kPpapiFlashArgs)); | 97 command_line.GetSwitchValueASCII(switches::kPpapiFlashArgs)); |
| 98 | 98 |
| 99 webkit_platform_support_.reset(new PpapiWebKitPlatformSupportImpl); | 99 webkit_platform_support_.reset(new PpapiWebKitPlatformSupportImpl); |
| 100 WebKit::initialize(webkit_platform_support_.get()); | 100 WebKit::initialize(webkit_platform_support_.get()); |
| 101 | 101 |
| 102 // Register interfaces that expect messages from the browser process. Please | 102 // Register interfaces that expect messages from the browser process. Please |
| 103 // note that only those InterfaceProxy-based ones require registration. | 103 // note that only those InterfaceProxy-based ones require registration. |
| 104 AddRoute(ppapi::API_ID_PPB_TCPSERVERSOCKET_PRIVATE, | |
| 105 &dispatcher_message_listener_); | |
| 106 AddRoute(ppapi::API_ID_PPB_TCPSOCKET, | 104 AddRoute(ppapi::API_ID_PPB_TCPSOCKET, |
| 107 &dispatcher_message_listener_); | 105 &dispatcher_message_listener_); |
| 108 AddRoute(ppapi::API_ID_PPB_TCPSOCKET_PRIVATE, | 106 AddRoute(ppapi::API_ID_PPB_TCPSOCKET_PRIVATE, |
| 109 &dispatcher_message_listener_); | 107 &dispatcher_message_listener_); |
| 110 AddRoute(ppapi::API_ID_PPB_UDPSOCKET_PRIVATE, | |
| 111 &dispatcher_message_listener_); | |
| 112 AddRoute(ppapi::API_ID_PPB_HOSTRESOLVER_PRIVATE, | 108 AddRoute(ppapi::API_ID_PPB_HOSTRESOLVER_PRIVATE, |
| 113 &dispatcher_message_listener_); | 109 &dispatcher_message_listener_); |
| 114 AddRoute(ppapi::API_ID_PPB_NETWORKMANAGER_PRIVATE, | 110 AddRoute(ppapi::API_ID_PPB_NETWORKMANAGER_PRIVATE, |
| 115 &dispatcher_message_listener_); | 111 &dispatcher_message_listener_); |
| 116 } | 112 } |
| 117 | 113 |
| 118 PpapiThread::~PpapiThread() { | 114 PpapiThread::~PpapiThread() { |
| 119 } | 115 } |
| 120 | 116 |
| 121 void PpapiThread::Shutdown() { | 117 void PpapiThread::Shutdown() { |
| (...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 515 histogram_name.str(), | 511 histogram_name.str(), |
| 516 1, | 512 1, |
| 517 LOAD_RESULT_MAX, | 513 LOAD_RESULT_MAX, |
| 518 LOAD_RESULT_MAX + 1, | 514 LOAD_RESULT_MAX + 1, |
| 519 base::HistogramBase::kUmaTargetedHistogramFlag); | 515 base::HistogramBase::kUmaTargetedHistogramFlag); |
| 520 | 516 |
| 521 histogram->Add(result); | 517 histogram->Add(result); |
| 522 } | 518 } |
| 523 | 519 |
| 524 } // namespace content | 520 } // namespace content |
| OLD | NEW |