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

Unified Diff: components/content_settings/core/common/content_settings_types.h

Issue 2675483002: Replace PermissionType in chrome/ with ContentSettingsType (Closed)
Patch Set: ready Created 3 years, 10 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: components/content_settings/core/common/content_settings_types.h
diff --git a/components/content_settings/core/common/content_settings_types.h b/components/content_settings/core/common/content_settings_types.h
index e89357643200cd9d92965054159b215287ab04c1..ccf58ddb4ed761bfb083f75464e1bbb270079b13 100644
--- a/components/content_settings/core/common/content_settings_types.h
+++ b/components/content_settings/core/common/content_settings_types.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_TYPES_H_
#define COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_TYPES_H_
+#include <cstddef>
+
#include "build/build_config.h"
// A particular type of content to care about. We give the user various types
@@ -47,8 +49,18 @@ enum ContentSettingsType {
CONTENT_SETTINGS_TYPE_IMPORTANT_SITE_INFO,
CONTENT_SETTINGS_TYPE_PERMISSION_AUTOBLOCKER_DATA,
+ // This is only here temporarily and will be removed when we further unify
+ // it with notifications.
raymes 2017/02/07 04:46:15 We should add a bug here.
raymes 2017/02/07 04:50:55 crbug.com/563297
Timothy Loh 2017/02/08 04:01:06 Done.
+ CONTENT_SETTINGS_TYPE_PUSH_MESSAGING,
+
// WARNING: This enum is going to be removed soon. Do not depend on NUM_TYPES.
CONTENT_SETTINGS_NUM_TYPES_DO_NOT_USE,
};
+struct ContentSettingsTypeHash {
+ std::size_t operator()(ContentSettingsType type) const {
+ return static_cast<std::size_t>(type);
+ }
+};
+
#endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_TYPES_H_

Powered by Google App Engine
This is Rietveld 408576698