| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/plugin_module.h" | 5 #include "webkit/plugins/ppapi/plugin_module.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 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 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 // identifiers. | 123 // identifiers. |
| 124 typedef std::set<PluginModule*> PluginModuleSet; | 124 typedef std::set<PluginModule*> PluginModuleSet; |
| 125 | 125 |
| 126 PluginModuleSet* GetLivePluginSet() { | 126 PluginModuleSet* GetLivePluginSet() { |
| 127 static PluginModuleSet live_plugin_libs; | 127 static PluginModuleSet live_plugin_libs; |
| 128 return &live_plugin_libs; | 128 return &live_plugin_libs; |
| 129 } | 129 } |
| 130 | 130 |
| 131 base::MessageLoopProxy* GetMainThreadMessageLoop() { | 131 base::MessageLoopProxy* GetMainThreadMessageLoop() { |
| 132 static scoped_refptr<base::MessageLoopProxy> proxy( | 132 static scoped_refptr<base::MessageLoopProxy> proxy( |
| 133 base::MessageLoopProxy::CreateForCurrentThread()); | 133 base::MessageLoopProxy::current()); |
| 134 return proxy.get(); | 134 return proxy.get(); |
| 135 } | 135 } |
| 136 | 136 |
| 137 // PPB_Core -------------------------------------------------------------------- | 137 // PPB_Core -------------------------------------------------------------------- |
| 138 | 138 |
| 139 void AddRefResource(PP_Resource resource) { | 139 void AddRefResource(PP_Resource resource) { |
| 140 if (!ResourceTracker::Get()->AddRefResource(resource)) { | 140 if (!ResourceTracker::Get()->AddRefResource(resource)) { |
| 141 DLOG(WARNING) << "AddRefResource()ing a nonexistent resource " << resource; | 141 DLOG(WARNING) << "AddRefResource()ing a nonexistent resource " << resource; |
| 142 } | 142 } |
| 143 } | 143 } |
| (...skipping 448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 592 int retval = entry_points.initialize_module(pp_module(), &GetInterface); | 592 int retval = entry_points.initialize_module(pp_module(), &GetInterface); |
| 593 if (retval != 0) { | 593 if (retval != 0) { |
| 594 LOG(WARNING) << "PPP_InitializeModule returned failure " << retval; | 594 LOG(WARNING) << "PPP_InitializeModule returned failure " << retval; |
| 595 return false; | 595 return false; |
| 596 } | 596 } |
| 597 return true; | 597 return true; |
| 598 } | 598 } |
| 599 | 599 |
| 600 } // namespace ppapi | 600 } // namespace ppapi |
| 601 } // namespace webkit | 601 } // namespace webkit |
| OLD | NEW |