Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(348)

Side by Side Diff: chrome/browser/extensions/extension_service.h

Issue 6772022: Make <all_urls> and file:///* in permissions trigger "Allow file access" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch for landing Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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
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
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_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_prefs.cc ('k') | chrome/browser/extensions/extension_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698