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 "ppapi/proxy/plugin_dispatcher.h" | 5 #include "ppapi/proxy/plugin_dispatcher.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 | 8 |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 "the |interface_name()| template function to the interface's C++ " | 109 "the |interface_name()| template function to the interface's C++ " |
110 "wrapper?"; | 110 "wrapper?"; |
111 return NULL; | 111 return NULL; |
112 } | 112 } |
113 | 113 |
114 return InterfaceList::GetInstance()->GetInterfaceForPPB(interface_name); | 114 return InterfaceList::GetInstance()->GetInterfaceForPPB(interface_name); |
115 } | 115 } |
116 | 116 |
117 // static | 117 // static |
118 void PluginDispatcher::LogWithSource(PP_Instance instance, | 118 void PluginDispatcher::LogWithSource(PP_Instance instance, |
119 PP_LogLevel_Dev level, | 119 PP_LogLevel level, |
120 const std::string& source, | 120 const std::string& source, |
121 const std::string& value) { | 121 const std::string& value) { |
122 if (!g_live_dispatchers || !g_instance_to_dispatcher) | 122 if (!g_live_dispatchers || !g_instance_to_dispatcher) |
123 return; | 123 return; |
124 | 124 |
125 if (instance) { | 125 if (instance) { |
126 InstanceToDispatcherMap::iterator found = | 126 InstanceToDispatcherMap::iterator found = |
127 g_instance_to_dispatcher->find(instance); | 127 g_instance_to_dispatcher->find(instance); |
128 if (found != g_instance_to_dispatcher->end()) { | 128 if (found != g_instance_to_dispatcher->end()) { |
129 // Send just to this specific dispatcher. | 129 // Send just to this specific dispatcher. |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
344 if (!resource) { | 344 if (!resource) { |
345 if (reply_params.sequence()) | 345 if (reply_params.sequence()) |
346 NOTREACHED(); | 346 NOTREACHED(); |
347 return; | 347 return; |
348 } | 348 } |
349 resource->OnReplyReceived(reply_params, nested_msg); | 349 resource->OnReplyReceived(reply_params, nested_msg); |
350 } | 350 } |
351 | 351 |
352 } // namespace proxy | 352 } // namespace proxy |
353 } // namespace ppapi | 353 } // namespace ppapi |
OLD | NEW |