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

Side by Side Diff: ppapi/proxy/plugin_var_tracker.h

Issue 7189045: Make o.o.p. proxy handle PPP_Instance versions 0.4 and 0.5. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merged Created 9 years, 5 months 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 | « ppapi/proxy/plugin_resource_tracker.h ('k') | ppapi/proxy/ppapi_proxy_test.h » ('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) 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 #ifndef PPAPI_PROXY_PLUGIN_VAR_TRACKER_H_ 5 #ifndef PPAPI_PROXY_PLUGIN_VAR_TRACKER_H_
6 #define PPAPI_PROXY_PLUGIN_VAR_TRACKER_H_ 6 #define PPAPI_PROXY_PLUGIN_VAR_TRACKER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 const PP_Var& host_object); 81 const PP_Var& host_object);
82 82
83 // Retrieves the internal reference counts for testing. Returns 0 if we 83 // Retrieves the internal reference counts for testing. Returns 0 if we
84 // know about the object but the corresponding value is 0, or -1 if the 84 // know about the object but the corresponding value is 0, or -1 if the
85 // given object ID isn't in our map. 85 // given object ID isn't in our map.
86 int GetRefCountForObject(const PP_Var& plugin_object); 86 int GetRefCountForObject(const PP_Var& plugin_object);
87 int GetTrackedWithNoReferenceCountForObject(const PP_Var& plugin_object); 87 int GetTrackedWithNoReferenceCountForObject(const PP_Var& plugin_object);
88 88
89 private: 89 private:
90 friend struct DefaultSingletonTraits<PluginVarTracker>; 90 friend struct DefaultSingletonTraits<PluginVarTracker>;
91 friend class PluginProxyTest; 91 friend class PluginProxyTestHarness;
92 92
93 class RefCountedString : public base::RefCounted<RefCountedString> { 93 class RefCountedString : public base::RefCounted<RefCountedString> {
94 public: 94 public:
95 RefCountedString() { 95 RefCountedString() {
96 } 96 }
97 RefCountedString(const std::string& str) : value_(str) { 97 RefCountedString(const std::string& str) : value_(str) {
98 } 98 }
99 RefCountedString(const char* data, size_t len) 99 RefCountedString(const char* data, size_t len)
100 : value_(data, len) { 100 : value_(data, len) {
101 } 101 }
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 VarID last_plugin_var_id_; 187 VarID last_plugin_var_id_;
188 188
189 // Get a new Var ID and increment last_plugin_var_id_. 189 // Get a new Var ID and increment last_plugin_var_id_.
190 VarID GetNewVarID(); 190 VarID GetNewVarID();
191 }; 191 };
192 192
193 } // namespace proxy 193 } // namespace proxy
194 } // namespace pp 194 } // namespace pp
195 195
196 #endif // PPAPI_PROXY_PLUGIN_VAR_TRACKER_H_ 196 #endif // PPAPI_PROXY_PLUGIN_VAR_TRACKER_H_
OLDNEW
« no previous file with comments | « ppapi/proxy/plugin_resource_tracker.h ('k') | ppapi/proxy/ppapi_proxy_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698