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

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

Issue 6282007: First pass at making the proxy handle multiple renderers. This associates the... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 11 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/ppb_url_request_info_proxy.cc ('k') | ppapi/proxy/ppb_url_response_info_proxy.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_PPB_URL_RESPONSE_INFO_PROXY_H_ 5 #ifndef PPAPI_PROXY_PPB_URL_RESPONSE_INFO_PROXY_H_
6 #define PPAPI_PROXY_PPB_URL_RESPONSE_INFO_PROXY_H_ 6 #define PPAPI_PROXY_PPB_URL_RESPONSE_INFO_PROXY_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "ppapi/c/pp_instance.h"
9 #include "ppapi/c/pp_module.h" 10 #include "ppapi/c/pp_module.h"
10 #include "ppapi/c/pp_resource.h" 11 #include "ppapi/c/pp_resource.h"
11 #include "ppapi/proxy/interface_proxy.h" 12 #include "ppapi/proxy/interface_proxy.h"
12 13
13 struct PPB_URLResponseInfo; 14 struct PPB_URLResponseInfo;
14 15
15 namespace pp { 16 namespace pp {
16 namespace proxy { 17 namespace proxy {
17 18
18 class SerializedVarReturnValue; 19 class SerializedVarReturnValue;
19 20
20 class PPB_URLResponseInfo_Proxy : public InterfaceProxy { 21 class PPB_URLResponseInfo_Proxy : public InterfaceProxy {
21 public: 22 public:
22 PPB_URLResponseInfo_Proxy(Dispatcher* dispatcher, 23 PPB_URLResponseInfo_Proxy(Dispatcher* dispatcher,
23 const void* target_interface); 24 const void* target_interface);
24 virtual ~PPB_URLResponseInfo_Proxy(); 25 virtual ~PPB_URLResponseInfo_Proxy();
25 26
26 // URLResponseInfo objects are actually returned by the URLLoader class. 27 // URLResponseInfo objects are actually returned by the URLLoader class.
27 // This function allows the URLLoader proxy to start the tracking of 28 // This function allows the URLLoader proxy to start the tracking of
28 // a response info object in the plugin. 29 // a response info object in the plugin.
29 static void TrackPluginResource(PP_Resource response_resource); 30 static void TrackPluginResource(PP_Instance instance,
31 PP_Resource response_resource);
30 32
31 const PPB_URLResponseInfo* ppb_url_response_info_target() const { 33 const PPB_URLResponseInfo* ppb_url_response_info_target() const {
32 return static_cast<const PPB_URLResponseInfo*>(target_interface()); 34 return static_cast<const PPB_URLResponseInfo*>(target_interface());
33 } 35 }
34 36
35 // InterfaceProxy implementation. 37 // InterfaceProxy implementation.
36 virtual const void* GetSourceInterface() const; 38 virtual const void* GetSourceInterface() const;
37 virtual InterfaceID GetInterfaceId() const; 39 virtual InterfaceID GetInterfaceId() const;
38 virtual bool OnMessageReceived(const IPC::Message& msg); 40 virtual bool OnMessageReceived(const IPC::Message& msg);
39 41
40 private: 42 private:
41 // Message handlers. 43 // Message handlers.
42 void OnMsgGetProperty(PP_Resource response, 44 void OnMsgGetProperty(PP_Resource response,
43 int32_t property, 45 int32_t property,
44 SerializedVarReturnValue result); 46 SerializedVarReturnValue result);
45 void OnMsgGetBodyAsFileRef(PP_Resource response, 47 void OnMsgGetBodyAsFileRef(PP_Resource response,
46 PP_Resource* file_ref_result); 48 PP_Resource* file_ref_result);
47 49
48 DISALLOW_COPY_AND_ASSIGN(PPB_URLResponseInfo_Proxy); 50 DISALLOW_COPY_AND_ASSIGN(PPB_URLResponseInfo_Proxy);
49 }; 51 };
50 52
51 } // namespace proxy 53 } // namespace proxy
52 } // namespace pp 54 } // namespace pp
53 55
54 #endif // PPAPI_PROXY_PPB_URL_RESPONSE_INFO_PROXY_H_ 56 #endif // PPAPI_PROXY_PPB_URL_RESPONSE_INFO_PROXY_H_
OLDNEW
« no previous file with comments | « ppapi/proxy/ppb_url_request_info_proxy.cc ('k') | ppapi/proxy/ppb_url_response_info_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698