| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "content/browser/renderer_host/pepper/pepper_internal_file_ref_backend.
h" | 5 #include "content/browser/renderer_host/pepper/pepper_internal_file_ref_backend.
h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/callback.h" | 9 #include "base/callback.h" |
| 10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 #include "ppapi/proxy/ppapi_messages.h" | 26 #include "ppapi/proxy/ppapi_messages.h" |
| 27 #include "ppapi/shared_impl/file_ref_create_info.h" | 27 #include "ppapi/shared_impl/file_ref_create_info.h" |
| 28 #include "ppapi/shared_impl/file_ref_util.h" | 28 #include "ppapi/shared_impl/file_ref_util.h" |
| 29 #include "ppapi/shared_impl/file_type_conversion.h" | 29 #include "ppapi/shared_impl/file_type_conversion.h" |
| 30 #include "ppapi/shared_impl/scoped_pp_var.h" | 30 #include "ppapi/shared_impl/scoped_pp_var.h" |
| 31 #include "ppapi/shared_impl/time_conversion.h" | 31 #include "ppapi/shared_impl/time_conversion.h" |
| 32 #include "ppapi/shared_impl/var.h" | 32 #include "ppapi/shared_impl/var.h" |
| 33 #include "ppapi/thunk/enter.h" | 33 #include "ppapi/thunk/enter.h" |
| 34 #include "ppapi/thunk/ppb_file_ref_api.h" | 34 #include "ppapi/thunk/ppb_file_ref_api.h" |
| 35 #include "ppapi/thunk/ppb_file_system_api.h" | 35 #include "ppapi/thunk/ppb_file_system_api.h" |
| 36 #include "storage/browser/fileapi/file_system_operation.h" |
| 37 #include "storage/browser/fileapi/file_system_operation_runner.h" |
| 38 #include "storage/browser/fileapi/file_system_url.h" |
| 36 #include "storage/common/fileapi/file_system_util.h" | 39 #include "storage/common/fileapi/file_system_util.h" |
| 37 #include "webkit/browser/fileapi/file_system_operation.h" | |
| 38 #include "webkit/browser/fileapi/file_system_operation_runner.h" | |
| 39 #include "webkit/browser/fileapi/file_system_url.h" | |
| 40 | 40 |
| 41 using ppapi::host::PpapiHost; | 41 using ppapi::host::PpapiHost; |
| 42 using ppapi::host::ResourceHost; | 42 using ppapi::host::ResourceHost; |
| 43 | 43 |
| 44 namespace content { | 44 namespace content { |
| 45 | 45 |
| 46 PepperInternalFileRefBackend::PepperInternalFileRefBackend( | 46 PepperInternalFileRefBackend::PepperInternalFileRefBackend( |
| 47 PpapiHost* host, | 47 PpapiHost* host, |
| 48 int render_process_id, | 48 int render_process_id, |
| 49 base::WeakPtr<PepperFileSystemBrowserHost> fs_host, | 49 base::WeakPtr<PepperFileSystemBrowserHost> fs_host, |
| (...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 300 ChildProcessSecurityPolicyImpl* policy = | 300 ChildProcessSecurityPolicyImpl* policy = |
| 301 ChildProcessSecurityPolicyImpl::GetInstance(); | 301 ChildProcessSecurityPolicyImpl::GetInstance(); |
| 302 if (!policy->CanReadFileSystemFile(render_process_id_, url) || | 302 if (!policy->CanReadFileSystemFile(render_process_id_, url) || |
| 303 !policy->CanWriteFileSystemFile(render_process_id_, url)) { | 303 !policy->CanWriteFileSystemFile(render_process_id_, url)) { |
| 304 return PP_ERROR_NOACCESS; | 304 return PP_ERROR_NOACCESS; |
| 305 } | 305 } |
| 306 return PP_OK; | 306 return PP_OK; |
| 307 } | 307 } |
| 308 | 308 |
| 309 } // namespace content | 309 } // namespace content |
| OLD | NEW |