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

Unified Diff: ppapi/proxy/ppb_file_system_proxy.cc

Issue 10081020: PPAPI: Make blocking completion callbacks work. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Updated TestURLLoader to test blocking callbacks. Created 8 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/proxy/ppb_file_system_proxy.cc
diff --git a/ppapi/proxy/ppb_file_system_proxy.cc b/ppapi/proxy/ppb_file_system_proxy.cc
index 993c468b0ffa200e87204f43ef96bc99a0665944..330b5800a5d73dd91fd08db1fdd83869a6ba0b6d 100644
--- a/ppapi/proxy/ppb_file_system_proxy.cc
+++ b/ppapi/proxy/ppb_file_system_proxy.cc
@@ -47,7 +47,7 @@ class FileSystem : public Resource, public PPB_FileSystem_API {
// PPB_FileSystem_APi implementation.
virtual int32_t Open(int64_t expected_size,
- PP_CompletionCallback callback) OVERRIDE;
+ ApiCallbackType callback) OVERRIDE;
virtual PP_FileSystemType GetType() OVERRIDE;
// Called when the host has responded to our open request.
@@ -76,13 +76,13 @@ PPB_FileSystem_API* FileSystem::AsPPB_FileSystem_API() {
}
int32_t FileSystem::Open(int64_t expected_size,
- PP_CompletionCallback callback) {
+ ApiCallbackType callback) {
if (TrackedCallback::IsPending(current_open_callback_))
return PP_ERROR_INPROGRESS;
if (called_open_)
return PP_ERROR_FAILED;
- current_open_callback_ = new TrackedCallback(this, callback);
+ current_open_callback_ = callback;
called_open_ = true;
PluginDispatcher::GetForResource(this)->Send(
new PpapiHostMsg_PPBFileSystem_Open(

Powered by Google App Engine
This is Rietveld 408576698