OLD | NEW |
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_PPB_FILE_REF_PROXY_H_ | 5 #ifndef PPAPI_PROXY_PPB_FILE_REF_PROXY_H_ |
6 #define PPAPI_PROXY_PPB_FILE_REF_PROXY_H_ | 6 #define PPAPI_PROXY_PPB_FILE_REF_PROXY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/bind_helpers.h" |
| 12 #include "ppapi/c/pp_file_info.h" |
11 #include "ppapi/c/pp_module.h" | 13 #include "ppapi/c/pp_module.h" |
12 #include "ppapi/c/pp_resource.h" | 14 #include "ppapi/c/pp_resource.h" |
13 #include "ppapi/c/pp_time.h" | 15 #include "ppapi/c/pp_time.h" |
14 #include "ppapi/proxy/interface_proxy.h" | 16 #include "ppapi/proxy/interface_proxy.h" |
15 #include "ppapi/proxy/ppapi_proxy_export.h" | 17 #include "ppapi/proxy/ppapi_proxy_export.h" |
16 #include "ppapi/proxy/proxy_completion_callback_factory.h" | 18 #include "ppapi/proxy/proxy_completion_callback_factory.h" |
17 #include "ppapi/utility/completion_callback_factory.h" | 19 #include "ppapi/utility/completion_callback_factory.h" |
18 | 20 |
19 namespace ppapi { | 21 namespace ppapi { |
20 | 22 |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 | 64 |
63 private: | 65 private: |
64 // Plugin -> host message handlers. | 66 // Plugin -> host message handlers. |
65 void OnMsgCreate(const HostResource& file_system, | 67 void OnMsgCreate(const HostResource& file_system, |
66 const std::string& path, | 68 const std::string& path, |
67 PPB_FileRef_CreateInfo* result); | 69 PPB_FileRef_CreateInfo* result); |
68 void OnMsgGetParent(const HostResource& host_resource, | 70 void OnMsgGetParent(const HostResource& host_resource, |
69 PPB_FileRef_CreateInfo* result); | 71 PPB_FileRef_CreateInfo* result); |
70 void OnMsgMakeDirectory(const HostResource& host_resource, | 72 void OnMsgMakeDirectory(const HostResource& host_resource, |
71 PP_Bool make_ancestors, | 73 PP_Bool make_ancestors, |
72 int callback_id); | 74 uint32_t callback_id); |
73 void OnMsgTouch(const HostResource& host_resource, | 75 void OnMsgTouch(const HostResource& host_resource, |
74 PP_Time last_access, | 76 PP_Time last_access, |
75 PP_Time last_modified, | 77 PP_Time last_modified, |
76 int callback_id); | 78 uint32_t callback_id); |
77 void OnMsgDelete(const HostResource& host_resource, | 79 void OnMsgDelete(const HostResource& host_resource, |
78 int callback_id); | 80 uint32_t callback_id); |
79 void OnMsgRename(const HostResource& file_ref, | 81 void OnMsgRename(const HostResource& file_ref, |
80 const HostResource& new_file_ref, | 82 const HostResource& new_file_ref, |
81 int callback_id); | 83 uint32_t callback_id); |
| 84 void OnMsgQuery(const HostResource& file_ref, |
| 85 uint32_t callback_id); |
82 void OnMsgGetAbsolutePath(const HostResource& host_resource, | 86 void OnMsgGetAbsolutePath(const HostResource& host_resource, |
83 SerializedVarReturnValue result); | 87 SerializedVarReturnValue result); |
84 | 88 |
85 // Host -> Plugin message handlers. | 89 // Host -> Plugin message handlers. |
86 void OnMsgCallbackComplete(const HostResource& host_resource, | 90 void OnMsgCallbackComplete(const HostResource& host_resource, |
87 int callback_id, | 91 uint32_t callback_id, |
88 int32_t result); | 92 int32_t result); |
| 93 void OnMsgQueryCallbackComplete(const HostResource& host_resource, |
| 94 const PP_FileInfo& info, |
| 95 uint32_t callback_id, |
| 96 int32_t result); |
89 | 97 |
90 void OnCallbackCompleteInHost(int32_t result, | 98 void OnCallbackCompleteInHost(int32_t result, |
91 const HostResource& host_resource, | 99 const HostResource& host_resource, |
92 int callback_id); | 100 uint32_t callback_id); |
| 101 void OnQueryCallbackCompleteInHost( |
| 102 int32_t result, |
| 103 const HostResource& host_resource, |
| 104 base::internal::OwnedWrapper<PP_FileInfo> info, |
| 105 uint32_t callback_id); |
93 | 106 |
94 ProxyCompletionCallbackFactory<PPB_FileRef_Proxy> callback_factory_; | 107 ProxyCompletionCallbackFactory<PPB_FileRef_Proxy> callback_factory_; |
95 | 108 |
96 DISALLOW_COPY_AND_ASSIGN(PPB_FileRef_Proxy); | 109 DISALLOW_COPY_AND_ASSIGN(PPB_FileRef_Proxy); |
97 }; | 110 }; |
98 | 111 |
99 } // namespace proxy | 112 } // namespace proxy |
100 } // namespace ppapi | 113 } // namespace ppapi |
101 | 114 |
102 #endif // PPAPI_PROXY_PPB_FILE_REF_PROXY_H_ | 115 #endif // PPAPI_PROXY_PPB_FILE_REF_PROXY_H_ |
OLD | NEW |