| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 157 // Whether this extension can run in an incognito window. | 157 // Whether this extension can run in an incognito window. |
| 158 bool IsIncognitoEnabled(const Extension* extension); | 158 bool IsIncognitoEnabled(const Extension* extension); |
| 159 void SetIsIncognitoEnabled(const Extension* extension, bool enabled); | 159 void SetIsIncognitoEnabled(const Extension* extension, bool enabled); |
| 160 | 160 |
| 161 // Returns true if the given extension can see events and data from another | 161 // Returns true if the given extension can see events and data from another |
| 162 // sub-profile (incognito to original profile, or vice versa). | 162 // sub-profile (incognito to original profile, or vice versa). |
| 163 bool CanCrossIncognito(const Extension* extension); | 163 bool CanCrossIncognito(const Extension* extension); |
| 164 | 164 |
| 165 // Whether this extension can inject scripts into pages with file URLs. | 165 // Whether this extension can inject scripts into pages with file URLs. |
| 166 bool AllowFileAccess(const Extension* extension); | 166 bool AllowFileAccess(const Extension* extension); |
| 167 // Will reload the extension since this permission is applied at loading time |
| 168 // only. |
| 167 void SetAllowFileAccess(const Extension* extension, bool allow); | 169 void SetAllowFileAccess(const Extension* extension, bool allow); |
| 168 | 170 |
| 169 // Getter and setter for the Browser Action visibility in the toolbar. | 171 // Getter and setter for the Browser Action visibility in the toolbar. |
| 170 bool GetBrowserActionVisibility(const Extension* extension); | 172 bool GetBrowserActionVisibility(const Extension* extension); |
| 171 void SetBrowserActionVisibility(const Extension* extension, bool visible); | 173 void SetBrowserActionVisibility(const Extension* extension, bool visible); |
| 172 | 174 |
| 173 // Whether the background page, if any, is ready. We don't load other | 175 // Whether the background page, if any, is ready. We don't load other |
| 174 // components until then. If there is no background page, we consider it to | 176 // components until then. If there is no background page, we consider it to |
| 175 // be ready. | 177 // be ready. |
| 176 bool IsBackgroundPageReady(const Extension* extension); | 178 bool IsBackgroundPageReady(const Extension* extension); |
| (...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 555 bool external_extension_url_added_; | 557 bool external_extension_url_added_; |
| 556 | 558 |
| 557 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, | 559 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, |
| 558 InstallAppsWithUnlimtedStorage); | 560 InstallAppsWithUnlimtedStorage); |
| 559 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, | 561 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, |
| 560 InstallAppsAndCheckStorageProtection); | 562 InstallAppsAndCheckStorageProtection); |
| 561 DISALLOW_COPY_AND_ASSIGN(ExtensionService); | 563 DISALLOW_COPY_AND_ASSIGN(ExtensionService); |
| 562 }; | 564 }; |
| 563 | 565 |
| 564 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ | 566 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ |
| OLD | NEW |