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

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

Issue 7655002: Convert the pp::proxy namespace to the ppapi::proxy namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 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
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 #include "ppapi/proxy/ppb_file_chooser_proxy.h" 5 #include "ppapi/proxy/ppb_file_chooser_proxy.h"
6 6
7 #include <queue> 7 #include <queue>
8 8
9 #include "ppapi/c/dev/ppb_file_chooser_dev.h" 9 #include "ppapi/c/dev/ppb_file_chooser_dev.h"
10 #include "ppapi/c/pp_errors.h" 10 #include "ppapi/c/pp_errors.h"
11 #include "ppapi/c/private/ppb_proxy_private.h" 11 #include "ppapi/c/private/ppb_proxy_private.h"
12 #include "ppapi/proxy/enter_proxy.h" 12 #include "ppapi/proxy/enter_proxy.h"
13 #include "ppapi/proxy/host_dispatcher.h" 13 #include "ppapi/proxy/host_dispatcher.h"
14 #include "ppapi/proxy/plugin_dispatcher.h" 14 #include "ppapi/proxy/plugin_dispatcher.h"
15 #include "ppapi/proxy/ppapi_messages.h" 15 #include "ppapi/proxy/ppapi_messages.h"
16 #include "ppapi/proxy/ppb_file_ref_proxy.h" 16 #include "ppapi/proxy/ppb_file_ref_proxy.h"
17 #include "ppapi/proxy/serialized_var.h" 17 #include "ppapi/proxy/serialized_var.h"
18 #include "ppapi/thunk/thunk.h" 18 #include "ppapi/thunk/thunk.h"
19 19
20 using ppapi::HostResource;
21 using ppapi::Resource;
22 using ppapi::thunk::PPB_FileChooser_API; 20 using ppapi::thunk::PPB_FileChooser_API;
23 21
24 namespace pp { 22 namespace ppapi {
25 namespace proxy { 23 namespace proxy {
26 24
27 class FileChooser : public Resource, 25 class FileChooser : public Resource,
28 public PPB_FileChooser_API { 26 public PPB_FileChooser_API {
29 public: 27 public:
30 FileChooser(const HostResource& resource); 28 FileChooser(const HostResource& resource);
31 virtual ~FileChooser(); 29 virtual ~FileChooser();
32 30
33 // Resource overrides. 31 // Resource overrides.
34 virtual PPB_FileChooser_API* AsPPB_FileChooser_API() OVERRIDE; 32 virtual PPB_FileChooser_API* AsPPB_FileChooser_API() OVERRIDE;
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 const void* target_interface) 130 const void* target_interface)
133 : InterfaceProxy(dispatcher, target_interface), 131 : InterfaceProxy(dispatcher, target_interface),
134 callback_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { 132 callback_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) {
135 } 133 }
136 134
137 PPB_FileChooser_Proxy::~PPB_FileChooser_Proxy() { 135 PPB_FileChooser_Proxy::~PPB_FileChooser_Proxy() {
138 } 136 }
139 137
140 const InterfaceProxy::Info* PPB_FileChooser_Proxy::GetInfo() { 138 const InterfaceProxy::Info* PPB_FileChooser_Proxy::GetInfo() {
141 static const Info info = { 139 static const Info info = {
142 ::ppapi::thunk::GetPPB_FileChooser_Thunk(), 140 thunk::GetPPB_FileChooser_Thunk(),
143 PPB_FILECHOOSER_DEV_INTERFACE, 141 PPB_FILECHOOSER_DEV_INTERFACE,
144 INTERFACE_ID_PPB_FILE_CHOOSER, 142 INTERFACE_ID_PPB_FILE_CHOOSER,
145 false, 143 false,
146 &CreateFileChooserProxy, 144 &CreateFileChooserProxy,
147 }; 145 };
148 return &info; 146 return &info;
149 } 147 }
150 148
151 // static 149 // static
152 PP_Resource PPB_FileChooser_Proxy::CreateProxyResource( 150 PP_Resource PPB_FileChooser_Proxy::CreateProxyResource(
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 file_ref_proxy->SerializeFileRef(cur_file_resource, &cur_create_info); 230 file_ref_proxy->SerializeFileRef(cur_file_resource, &cur_create_info);
233 files.push_back(cur_create_info); 231 files.push_back(cur_create_info);
234 } 232 }
235 } 233 }
236 234
237 dispatcher()->Send(new PpapiMsg_PPBFileChooser_ChooseComplete( 235 dispatcher()->Send(new PpapiMsg_PPBFileChooser_ChooseComplete(
238 INTERFACE_ID_PPB_FILE_CHOOSER, chooser, result, files)); 236 INTERFACE_ID_PPB_FILE_CHOOSER, chooser, result, files));
239 } 237 }
240 238
241 } // namespace proxy 239 } // namespace proxy
242 } // namespace pp 240 } // namespace ppapi
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698