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

Unified Diff: chrome/browser/ui/webui/site_settings_helper.h

Issue 2350303004: Site Settings Desktop: Fix crash when altering exception. (Closed)
Patch Set: Address feedback Created 4 years, 3 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/ui/webui/site_settings_helper.h
diff --git a/chrome/browser/ui/webui/site_settings_helper.h b/chrome/browser/ui/webui/site_settings_helper.h
index 4f3f29ddf525d0e42846416ecec700686f2306de..19847b1806fcf36b1a2d628041b42b71f0eb3a61 100644
--- a/chrome/browser/ui/webui/site_settings_helper.h
+++ b/chrome/browser/ui/webui/site_settings_helper.h
@@ -15,6 +15,7 @@
#include "components/content_settings/core/common/content_settings_pattern.h"
#include "components/content_settings/core/common/content_settings_types.h"
#include "content/public/browser/web_ui.h"
+#include "extensions/common/extension.h"
class ChooserContextBase;
class HostContentSettingsMap;
@@ -40,6 +41,7 @@ extern const char kSetting[];
extern const char kOrigin[];
extern const char kPolicyProviderId[];
extern const char kSource[];
+extern const char kIncognito[];
extern const char kEmbeddingOrigin[];
extern const char kPreferencesSource[];
@@ -55,6 +57,18 @@ ContentSettingsType ContentSettingsTypeFromGroupName(const std::string& name);
// Gets a string identifier for the group name.
std::string ContentSettingsTypeToGroupName(ContentSettingsType type);
+// Helper function to construct a dictonary for an exception.
+std::unique_ptr<base::DictionaryValue> GetExceptionForPage(
+ const ContentSettingsPattern& pattern,
+ const ContentSettingsPattern& secondary_pattern,
+ const ContentSetting& setting,
+ const std::string& provider_name,
+ bool incognito);
+
+// Helper function to construct a dictonary for a hosted app exception.
+void AddExceptionForHostedApp(const std::string& url_pattern,
+ const extensions::Extension& app, base::ListValue* exceptions);
+
// Fills in |exceptions| with Values for the given |type| from |map|.
// If |filter| is not null then only exceptions with matching primary patterns
// will be returned.
« no previous file with comments | « chrome/browser/ui/webui/settings/site_settings_handler_unittest.cc ('k') | chrome/browser/ui/webui/site_settings_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698