OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_system_proxy.h" | 5 #include "ppapi/proxy/ppb_file_system_proxy.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
9 #include "ppapi/c/pp_errors.h" | 9 #include "ppapi/c/pp_errors.h" |
10 #include "ppapi/c/ppb_file_system.h" | 10 #include "ppapi/c/ppb_file_system.h" |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 private: | 56 private: |
57 PP_FileSystemType type_; | 57 PP_FileSystemType type_; |
58 bool called_open_; | 58 bool called_open_; |
59 scoped_refptr<TrackedCallback> current_open_callback_; | 59 scoped_refptr<TrackedCallback> current_open_callback_; |
60 | 60 |
61 DISALLOW_COPY_AND_ASSIGN(FileSystem); | 61 DISALLOW_COPY_AND_ASSIGN(FileSystem); |
62 }; | 62 }; |
63 | 63 |
64 FileSystem::FileSystem(const HostResource& host_resource, | 64 FileSystem::FileSystem(const HostResource& host_resource, |
65 PP_FileSystemType type) | 65 PP_FileSystemType type) |
66 : Resource(host_resource), | 66 : Resource(OBJECT_IS_PROXY, host_resource), |
67 type_(type), | 67 type_(type), |
68 called_open_(false) { | 68 called_open_(false) { |
69 } | 69 } |
70 | 70 |
71 FileSystem::~FileSystem() { | 71 FileSystem::~FileSystem() { |
72 } | 72 } |
73 | 73 |
74 PPB_FileSystem_API* FileSystem::AsPPB_FileSystem_API() { | 74 PPB_FileSystem_API* FileSystem::AsPPB_FileSystem_API() { |
75 return this; | 75 return this; |
76 } | 76 } |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
176 | 176 |
177 void PPB_FileSystem_Proxy::OpenCompleteInHost( | 177 void PPB_FileSystem_Proxy::OpenCompleteInHost( |
178 int32_t result, | 178 int32_t result, |
179 const HostResource& host_resource) { | 179 const HostResource& host_resource) { |
180 dispatcher()->Send(new PpapiMsg_PPBFileSystem_OpenComplete( | 180 dispatcher()->Send(new PpapiMsg_PPBFileSystem_OpenComplete( |
181 API_ID_PPB_FILE_SYSTEM, host_resource, result)); | 181 API_ID_PPB_FILE_SYSTEM, host_resource, result)); |
182 } | 182 } |
183 | 183 |
184 } // namespace proxy | 184 } // namespace proxy |
185 } // namespace ppapi | 185 } // namespace ppapi |
OLD | NEW |