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 COMPONENTS_NACL_BROWSER_NACL_BROWSER_DELEGATE_H_ | 5 #ifndef COMPONENTS_NACL_BROWSER_NACL_BROWSER_DELEGATE_H_ |
6 #define COMPONENTS_NACL_BROWSER_NACL_BROWSER_DELEGATE_H_ | 6 #define COMPONENTS_NACL_BROWSER_NACL_BROWSER_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 // Returns true on success, false otherwise. On success, map |url| to a | 58 // Returns true on success, false otherwise. On success, map |url| to a |
59 // full pathname of a file in the local filesystem. |file_path| should not be | 59 // full pathname of a file in the local filesystem. |file_path| should not be |
60 // changed on failure. This mapping should be a best effort, for example, | 60 // changed on failure. This mapping should be a best effort, for example, |
61 // "chrome-extension:" could be mapped to the location of unpacked | 61 // "chrome-extension:" could be mapped to the location of unpacked |
62 // extensions. If this method is called in a blocking thread you should set | 62 // extensions. If this method is called in a blocking thread you should set |
63 // |use_blocking_api| to true, so calling blocking file API is allowed | 63 // |use_blocking_api| to true, so calling blocking file API is allowed |
64 // otherwise non blocking API will be used (which only handles a subset of the | 64 // otherwise non blocking API will be used (which only handles a subset of the |
65 // urls checking only the url scheme against kExtensionScheme). | 65 // urls checking only the url scheme against kExtensionScheme). |
66 virtual bool MapUrlToLocalFilePath(const GURL& url, | 66 virtual bool MapUrlToLocalFilePath(const GURL& url, |
67 bool use_blocking_api, | 67 bool use_blocking_api, |
| 68 const base::FilePath& profile_directory, |
68 base::FilePath* file_path) = 0; | 69 base::FilePath* file_path) = 0; |
69 // Set match patterns which will be checked before enabling debug stub. | 70 // Set match patterns which will be checked before enabling debug stub. |
70 virtual void SetDebugPatterns(std::string debug_patterns) = 0; | 71 virtual void SetDebugPatterns(std::string debug_patterns) = 0; |
71 | 72 |
72 // Returns whether NaCl application with this manifest URL should be debugged. | 73 // Returns whether NaCl application with this manifest URL should be debugged. |
73 virtual bool URLMatchesDebugPatterns(const GURL& manifest_url) = 0; | 74 virtual bool URLMatchesDebugPatterns(const GURL& manifest_url) = 0; |
74 | 75 |
75 // Returns a callback that handles NaCl idle state transitions. | 76 // Returns a callback that handles NaCl idle state transitions. |
76 virtual content::BrowserPpapiHost::OnKeepaliveCallback | 77 virtual content::BrowserPpapiHost::OnKeepaliveCallback |
77 GetOnKeepaliveCallback() = 0; | 78 GetOnKeepaliveCallback() = 0; |
78 }; | 79 }; |
79 | 80 |
80 #endif // COMPONENTS_NACL_BROWSER_NACL_BROWSER_DELEGATE_H_ | 81 #endif // COMPONENTS_NACL_BROWSER_NACL_BROWSER_DELEGATE_H_ |
OLD | NEW |