| 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 #ifndef CHROME_BROWSER_RENDERER_HOST_PEPPER_PEPPER_ISOLATED_FILE_SYSTEM_MESSAGE_
FILTER_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_PEPPER_PEPPER_ISOLATED_FILE_SYSTEM_MESSAGE_
FILTER_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_PEPPER_PEPPER_ISOLATED_FILE_SYSTEM_MESSAGE_
FILTER_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_PEPPER_PEPPER_ISOLATED_FILE_SYSTEM_MESSAGE_
FILTER_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 namespace chrome { | 31 namespace chrome { |
| 32 | 32 |
| 33 class PepperIsolatedFileSystemMessageFilter | 33 class PepperIsolatedFileSystemMessageFilter |
| 34 : public ppapi::host::ResourceMessageFilter { | 34 : public ppapi::host::ResourceMessageFilter { |
| 35 public: | 35 public: |
| 36 static PepperIsolatedFileSystemMessageFilter* Create( | 36 static PepperIsolatedFileSystemMessageFilter* Create( |
| 37 PP_Instance instance, | 37 PP_Instance instance, |
| 38 content::BrowserPpapiHost* host); | 38 content::BrowserPpapiHost* host); |
| 39 | 39 |
| 40 // ppapi::host::ResourceMessageFilter implementation. | 40 // ppapi::host::ResourceMessageFilter implementation. |
| 41 virtual scoped_refptr<base::TaskRunner> OverrideTaskRunnerForMessage( | 41 scoped_refptr<base::TaskRunner> OverrideTaskRunnerForMessage( |
| 42 const IPC::Message& msg) override; | 42 const IPC::Message& msg) override; |
| 43 virtual int32_t OnResourceMessageReceived( | 43 int32_t OnResourceMessageReceived( |
| 44 const IPC::Message& msg, | 44 const IPC::Message& msg, |
| 45 ppapi::host::HostMessageContext* context) override; | 45 ppapi::host::HostMessageContext* context) override; |
| 46 | 46 |
| 47 private: | 47 private: |
| 48 PepperIsolatedFileSystemMessageFilter(int render_process_id, | 48 PepperIsolatedFileSystemMessageFilter(int render_process_id, |
| 49 const base::FilePath& profile_directory, | 49 const base::FilePath& profile_directory, |
| 50 const GURL& document_url, | 50 const GURL& document_url, |
| 51 ppapi::host::PpapiHost* ppapi_host_); | 51 ppapi::host::PpapiHost* ppapi_host_); |
| 52 | 52 |
| 53 virtual ~PepperIsolatedFileSystemMessageFilter(); | 53 ~PepperIsolatedFileSystemMessageFilter() override; |
| 54 | 54 |
| 55 Profile* GetProfile(); | 55 Profile* GetProfile(); |
| 56 | 56 |
| 57 // Returns filesystem id of isolated filesystem if valid, or empty string | 57 // Returns filesystem id of isolated filesystem if valid, or empty string |
| 58 // otherwise. This must run on the UI thread because ProfileManager only | 58 // otherwise. This must run on the UI thread because ProfileManager only |
| 59 // allows access on that thread. | 59 // allows access on that thread. |
| 60 std::string CreateCrxFileSystem(Profile* profile); | 60 std::string CreateCrxFileSystem(Profile* profile); |
| 61 | 61 |
| 62 int32_t OnOpenFileSystem(ppapi::host::HostMessageContext* context, | 62 int32_t OnOpenFileSystem(ppapi::host::HostMessageContext* context, |
| 63 PP_IsolatedFileSystemType_Private type); | 63 PP_IsolatedFileSystemType_Private type); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 74 | 74 |
| 75 // Set of origins that can use CrxFs private APIs from NaCl. | 75 // Set of origins that can use CrxFs private APIs from NaCl. |
| 76 std::set<std::string> allowed_crxfs_origins_; | 76 std::set<std::string> allowed_crxfs_origins_; |
| 77 | 77 |
| 78 DISALLOW_COPY_AND_ASSIGN(PepperIsolatedFileSystemMessageFilter); | 78 DISALLOW_COPY_AND_ASSIGN(PepperIsolatedFileSystemMessageFilter); |
| 79 }; | 79 }; |
| 80 | 80 |
| 81 } // namespace chrome | 81 } // namespace chrome |
| 82 | 82 |
| 83 #endif // CHROME_BROWSER_RENDERER_HOST_PEPPER_PEPPER_ISOLATED_FILE_SYSTEM_MESSA
GE_FILTER_H_ | 83 #endif // CHROME_BROWSER_RENDERER_HOST_PEPPER_PEPPER_ISOLATED_FILE_SYSTEM_MESSA
GE_FILTER_H_ |
| OLD | NEW |