Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(477)

Side by Side Diff: ppapi/proxy/plugin_globals.cc

Issue 11189146: Eliminate implicit conversion from scoped_refptr<T> to T* (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/url_request/url_request.h ('k') | ppapi/shared_impl/callback_tracker.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_globals.h" 5 #include "ppapi/proxy/plugin_globals.h"
6 6
7 #include "ppapi/proxy/plugin_dispatcher.h" 7 #include "ppapi/proxy/plugin_dispatcher.h"
8 8
9 namespace ppapi { 9 namespace ppapi {
10 namespace proxy { 10 namespace proxy {
(...skipping 21 matching lines...) Expand all
32 } 32 }
33 33
34 ResourceTracker* PluginGlobals::GetResourceTracker() { 34 ResourceTracker* PluginGlobals::GetResourceTracker() {
35 return &plugin_resource_tracker_; 35 return &plugin_resource_tracker_;
36 } 36 }
37 37
38 VarTracker* PluginGlobals::GetVarTracker() { 38 VarTracker* PluginGlobals::GetVarTracker() {
39 return &plugin_var_tracker_; 39 return &plugin_var_tracker_;
40 } 40 }
41 41
42 CallbackTracker* PluginGlobals::GetCallbackTrackerForInstance( 42 scoped_refptr<CallbackTracker> PluginGlobals::GetCallbackTrackerForInstance(
43 PP_Instance instance) { 43 PP_Instance instance) {
44 // In the plugin process, the callback tracker is always the same, regardless 44 // In the plugin process, the callback tracker is always the same, regardless
45 // of the instance. 45 // of the instance.
46 return callback_tracker_.get(); 46 return callback_tracker_;
47 } 47 }
48 48
49 FunctionGroupBase* PluginGlobals::GetFunctionAPI(PP_Instance inst, ApiID id) { 49 FunctionGroupBase* PluginGlobals::GetFunctionAPI(PP_Instance inst, ApiID id) {
50 PluginDispatcher* dispatcher = PluginDispatcher::GetForInstance(inst); 50 PluginDispatcher* dispatcher = PluginDispatcher::GetForInstance(inst);
51 if (dispatcher) 51 if (dispatcher)
52 return dispatcher->GetFunctionAPI(id); 52 return dispatcher->GetFunctionAPI(id);
53 return NULL; 53 return NULL;
54 } 54 }
55 55
56 PP_Module PluginGlobals::GetModuleForInstance(PP_Instance instance) { 56 PP_Module PluginGlobals::GetModuleForInstance(PP_Instance instance) {
57 // Currently proxied plugins don't use the PP_Module for anything useful. 57 // Currently proxied plugins don't use the PP_Module for anything useful.
58 return 0; 58 return 0;
59 } 59 }
60 60
61 base::Lock* PluginGlobals::GetProxyLock() { 61 base::Lock* PluginGlobals::GetProxyLock() {
62 #ifdef ENABLE_PEPPER_THREADING 62 #ifdef ENABLE_PEPPER_THREADING
63 return &proxy_lock_; 63 return &proxy_lock_;
64 #else 64 #else
65 return NULL; 65 return NULL;
66 #endif 66 #endif
67 } 67 }
68 68
69 bool PluginGlobals::IsPluginGlobals() const { 69 bool PluginGlobals::IsPluginGlobals() const {
70 return true; 70 return true;
71 } 71 }
72 72
73 } // namespace proxy 73 } // namespace proxy
74 } // namespace ppapi 74 } // namespace ppapi
OLDNEW
« no previous file with comments | « net/url_request/url_request.h ('k') | ppapi/shared_impl/callback_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698