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

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

Issue 4747001: Move URLLoader, URLRequestInfo, and URLResponseInfo out of the dev directory... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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 | « ppapi/proxy/ppb_url_loader_proxy.h ('k') | ppapi/proxy/ppb_url_request_info_proxy.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) 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 #include "ppapi/proxy/ppb_url_loader_proxy.h" 5 #include "ppapi/proxy/ppb_url_loader_proxy.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
11 #include "ppapi/c/pp_completion_callback.h" 11 #include "ppapi/c/pp_completion_callback.h"
12 #include "ppapi/c/pp_errors.h" 12 #include "ppapi/c/pp_errors.h"
13 #include "ppapi/c/pp_resource.h" 13 #include "ppapi/c/pp_resource.h"
14 #include "ppapi/c/dev/ppb_url_loader_dev.h" 14 #include "ppapi/c/ppb_url_loader.h"
15 #include "ppapi/proxy/host_dispatcher.h" 15 #include "ppapi/proxy/host_dispatcher.h"
16 #include "ppapi/proxy/plugin_dispatcher.h" 16 #include "ppapi/proxy/plugin_dispatcher.h"
17 #include "ppapi/proxy/plugin_resource.h" 17 #include "ppapi/proxy/plugin_resource.h"
18 #include "ppapi/proxy/ppapi_messages.h" 18 #include "ppapi/proxy/ppapi_messages.h"
19 #include "ppapi/proxy/ppb_url_response_info_proxy.h" 19 #include "ppapi/proxy/ppb_url_response_info_proxy.h"
20 20
21 #if defined(OS_LINUX) 21 #if defined(OS_LINUX)
22 #include <sys/shm.h> 22 #include <sys/shm.h>
23 #endif 23 #endif
24 24
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 INTERFACE_ID_PPB_URL_LOADER, loader_id, 181 INTERFACE_ID_PPB_URL_LOADER, loader_id,
182 dispatcher->callback_tracker().SendCallback(callback))); 182 dispatcher->callback_tracker().SendCallback(callback)));
183 return PP_ERROR_WOULDBLOCK; 183 return PP_ERROR_WOULDBLOCK;
184 } 184 }
185 185
186 void Close(PP_Resource loader_id) { 186 void Close(PP_Resource loader_id) {
187 PluginDispatcher::Get()->Send(new PpapiHostMsg_PPBURLLoader_Close( 187 PluginDispatcher::Get()->Send(new PpapiHostMsg_PPBURLLoader_Close(
188 INTERFACE_ID_PPB_URL_LOADER, loader_id)); 188 INTERFACE_ID_PPB_URL_LOADER, loader_id));
189 } 189 }
190 190
191 const PPB_URLLoader_Dev ppb_urlloader = { 191 const PPB_URLLoader ppb_urlloader = {
192 &Create, 192 &Create,
193 &IsURLLoader, 193 &IsURLLoader,
194 &Open, 194 &Open,
195 &FollowRedirect, 195 &FollowRedirect,
196 &GetUploadProgress, 196 &GetUploadProgress,
197 &GetDownloadProgress, 197 &GetDownloadProgress,
198 &GetResponseInfo, 198 &GetResponseInfo,
199 &ReadResponseBody, 199 &ReadResponseBody,
200 &FinishStreamingToFile, 200 &FinishStreamingToFile,
201 &Close 201 &Close
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
410 // The plugin should be able to make a new request from their callback, so 410 // The plugin should be able to make a new request from their callback, so
411 // we have to clear our copy first. 411 // we have to clear our copy first.
412 PP_CompletionCallback temp_callback = object->current_read_callback_; 412 PP_CompletionCallback temp_callback = object->current_read_callback_;
413 object->current_read_callback_ = PP_BlockUntilComplete(); 413 object->current_read_callback_ = PP_BlockUntilComplete();
414 object->current_read_buffer_ = NULL; 414 object->current_read_buffer_ = NULL;
415 PP_RunCompletionCallback(&temp_callback, result); 415 PP_RunCompletionCallback(&temp_callback, result);
416 } 416 }
417 417
418 } // namespace proxy 418 } // namespace proxy
419 } // namespace pp 419 } // namespace pp
OLDNEW
« no previous file with comments | « ppapi/proxy/ppb_url_loader_proxy.h ('k') | ppapi/proxy/ppb_url_request_info_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698