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

Unified Diff: chrome/browser/content_settings/host_content_settings_map.h

Issue 7828022: Add a method to the HostContentSettings map to return the |Value| of a content setting (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/content_settings/host_content_settings_map.h
diff --git a/chrome/browser/content_settings/host_content_settings_map.h b/chrome/browser/content_settings/host_content_settings_map.h
index cc7150a8edcc11c2810b1b09453a947586cbeced..f6f3dcce7be07a4ceeb6b2450b0ed576763959ac 100644
--- a/chrome/browser/content_settings/host_content_settings_map.h
+++ b/chrome/browser/content_settings/host_content_settings_map.h
@@ -17,6 +17,7 @@
#include "base/basictypes.h"
#include "base/memory/linked_ptr.h"
#include "base/memory/ref_counted.h"
+#include "base/values.h"
#include "base/synchronization/lock.h"
#include "chrome/browser/content_settings/content_settings_pattern.h"
#include "chrome/browser/content_settings/content_settings_observer.h"
@@ -79,6 +80,19 @@ class HostContentSettingsMap
ContentSettingsType content_type,
const std::string& resource_identifier) const;
+ // Returns a content setting |Value| which applies to the given URLs. Note
+ // that certain internal schemes are whitelisted. For ContentSettingsTypes
+ // that require an resource identifier to be specified, the
wtc 2011/09/01 22:42:34 Nit: an => a You should fix this on line 73 above
markusheintz_ 2011/09/02 14:55:59 Done.
+ // |resource_identifier| must be non-empty. Ownership of the returned |Value|
+ // is transfered to the caller.
+ //
+ // This may be called on any thread.
+ Value* GetContentSettingValue(
+ const GURL& primary_url,
+ const GURL& secondary_url,
+ ContentSettingsType content_type,
+ const std::string& resource_identifier) const;
+
// Gets the content setting for cookies. This takes the third party cookie
// flag into account, and therefore needs to know whether we read or write a
// cookie.

Powered by Google App Engine
This is Rietveld 408576698