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_EXTENSIONS_EXTENSION_UTIL_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_UTIL_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_UTIL_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_UTIL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 | 45 |
46 // Returns true if |extension| can see events and data from another sub-profile | 46 // Returns true if |extension| can see events and data from another sub-profile |
47 // (incognito to original profile, or vice versa). | 47 // (incognito to original profile, or vice versa). |
48 bool CanCrossIncognito(const extensions::Extension* extension, | 48 bool CanCrossIncognito(const extensions::Extension* extension, |
49 content::BrowserContext* context); | 49 content::BrowserContext* context); |
50 | 50 |
51 // Returns true if |extension| can be loaded in incognito. | 51 // Returns true if |extension| can be loaded in incognito. |
52 bool CanLoadInIncognito(const extensions::Extension* extension, | 52 bool CanLoadInIncognito(const extensions::Extension* extension, |
53 content::BrowserContext* context); | 53 content::BrowserContext* context); |
54 | 54 |
| 55 // Returns true if the |extension| should not trigger a zoom bubble. |
| 56 bool ZoomWithoutBubble(const Extension* extension); |
| 57 |
55 // Returns true if this extension can inject scripts into pages with file URLs. | 58 // Returns true if this extension can inject scripts into pages with file URLs. |
56 bool AllowFileAccess(const std::string& extension_id, | 59 bool AllowFileAccess(const std::string& extension_id, |
57 content::BrowserContext* context); | 60 content::BrowserContext* context); |
58 | 61 |
59 // Sets whether |extension_id| can inject scripts into pages with file URLs. | 62 // Sets whether |extension_id| can inject scripts into pages with file URLs. |
60 // Reloads the extension if it's enabled since this permission is applied at | 63 // Reloads the extension if it's enabled since this permission is applied at |
61 // loading time only. Note than an ExtensionService must exist. | 64 // loading time only. Note than an ExtensionService must exist. |
62 void SetAllowFileAccess(const std::string& extension_id, | 65 void SetAllowFileAccess(const std::string& extension_id, |
63 content::BrowserContext* context, | 66 content::BrowserContext* context, |
64 bool allow); | 67 bool allow); |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 bool IsExtensionSupervised(const Extension* extension, Profile* profile); | 136 bool IsExtensionSupervised(const Extension* extension, Profile* profile); |
134 | 137 |
135 // Returns true if supervised users need approval from their custodian for | 138 // Returns true if supervised users need approval from their custodian for |
136 // approving escalated permissions on updated extensions. | 139 // approving escalated permissions on updated extensions. |
137 bool NeedCustodianApprovalForPermissionIncrease(); | 140 bool NeedCustodianApprovalForPermissionIncrease(); |
138 | 141 |
139 } // namespace util | 142 } // namespace util |
140 } // namespace extensions | 143 } // namespace extensions |
141 | 144 |
142 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_UTIL_H_ | 145 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_UTIL_H_ |
OLD | NEW |