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 "webkit/plugins/ppapi/host_globals.h" | 5 #include "webkit/plugins/ppapi/host_globals.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/logging.h" | 10 #include "base/logging.h" |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 GetAllContainersForModule(i->second, &containers); | 171 GetAllContainersForModule(i->second, &containers); |
172 } | 172 } |
173 } | 173 } |
174 | 174 |
175 WebConsoleMessage message = MakeLogMessage(level, source, value); | 175 WebConsoleMessage message = MakeLogMessage(level, source, value); |
176 for (ContainerSet::iterator i = containers.begin(); | 176 for (ContainerSet::iterator i = containers.begin(); |
177 i != containers.end(); ++i) | 177 i != containers.end(); ++i) |
178 (*i)->element().document().frame()->addMessageToConsole(message); | 178 (*i)->element().document().frame()->addMessageToConsole(message); |
179 } | 179 } |
180 | 180 |
| 181 ::ppapi::MessageLoopShared* HostGlobals::GetCurrentMessageLoop() { |
| 182 return NULL; |
| 183 } |
| 184 |
181 PP_Module HostGlobals::AddModule(PluginModule* module) { | 185 PP_Module HostGlobals::AddModule(PluginModule* module) { |
182 #ifndef NDEBUG | 186 #ifndef NDEBUG |
183 // Make sure we're not adding one more than once. | 187 // Make sure we're not adding one more than once. |
184 for (ModuleMap::const_iterator i = module_map_.begin(); | 188 for (ModuleMap::const_iterator i = module_map_.begin(); |
185 i != module_map_.end(); ++i) | 189 i != module_map_.end(); ++i) |
186 DCHECK(i->second != module); | 190 DCHECK(i->second != module); |
187 #endif | 191 #endif |
188 | 192 |
189 // See AddInstance. | 193 // See AddInstance. |
190 PP_Module new_module; | 194 PP_Module new_module; |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
257 return NULL; | 261 return NULL; |
258 return found->second; | 262 return found->second; |
259 } | 263 } |
260 | 264 |
261 bool HostGlobals::IsHostGlobals() const { | 265 bool HostGlobals::IsHostGlobals() const { |
262 return true; | 266 return true; |
263 } | 267 } |
264 | 268 |
265 } // namespace ppapi | 269 } // namespace ppapi |
266 } // namespace webkit | 270 } // namespace webkit |
OLD | NEW |