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

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

Issue 10821077: Add gallery permissions to Media Galleries Preferences (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix tests Created 8 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_prefs.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_PREFS_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 // Find the right launch container based on the launch type. 318 // Find the right launch container based on the launch type.
319 // If |extension|'s prefs do not have a launch type set, then 319 // If |extension|'s prefs do not have a launch type set, then
320 // use |default_pref_value|. 320 // use |default_pref_value|.
321 extension_misc::LaunchContainer GetLaunchContainer( 321 extension_misc::LaunchContainer GetLaunchContainer(
322 const Extension* extension, 322 const Extension* extension,
323 LaunchType default_pref_value); 323 LaunchType default_pref_value);
324 324
325 // Set and retrieve permissions for media galleries as identified by the 325 // Set and retrieve permissions for media galleries as identified by the
326 // gallery id. 326 // gallery id.
327 void SetMediaGalleryPermission(const std::string& extension_id, 327 void SetMediaGalleryPermission(const std::string& extension_id,
328 MediaGalleryPrefId gallery, bool has_access); 328 chrome::MediaGalleryPrefId gallery,
329 std::vector<MediaGalleryPermission> GetMediaGalleryPermissions( 329 bool has_access);
330 void UnsetMediaGalleryPermission(const std::string& extension_id,
331 chrome::MediaGalleryPrefId gallery);
332 std::vector<chrome::MediaGalleryPermission> GetMediaGalleryPermissions(
330 const std::string& extension_id); 333 const std::string& extension_id);
331 void RemoveMediaGalleryPermissions(MediaGalleryPrefId gallery_id); 334 void RemoveMediaGalleryPermissions(chrome::MediaGalleryPrefId gallery_id);
332 335
333 // Saves ExtensionInfo for each installed extension with the path to the 336 // Saves ExtensionInfo for each installed extension with the path to the
334 // version directory and the location. Blacklisted extensions won't be saved 337 // version directory and the location. Blacklisted extensions won't be saved
335 // and neither will external extensions the user has explicitly uninstalled. 338 // and neither will external extensions the user has explicitly uninstalled.
336 // Caller takes ownership of returned structure. 339 // Caller takes ownership of returned structure.
337 ExtensionsInfo* GetInstalledExtensionsInfo(); 340 ExtensionsInfo* GetInstalledExtensionsInfo();
338 341
339 // Returns the ExtensionInfo from the prefs for the given extension. If the 342 // Returns the ExtensionInfo from the prefs for the given extension. If the
340 // extension is not present, NULL is returned. 343 // extension is not present, NULL is returned.
341 ExtensionInfo* GetInstalledExtensionInfo(const std::string& extension_id); 344 ExtensionInfo* GetInstalledExtensionInfo(const std::string& extension_id);
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
567 scoped_ptr<ExtensionSorting> extension_sorting_; 570 scoped_ptr<ExtensionSorting> extension_sorting_;
568 571
569 scoped_refptr<ContentSettingsStore> content_settings_store_; 572 scoped_refptr<ContentSettingsStore> content_settings_store_;
570 573
571 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); 574 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs);
572 }; 575 };
573 576
574 } // namespace extensions 577 } // namespace extensions
575 578
576 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ 579 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_prefs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698