blob: 21bd42dfa4006221b039522892440377b0a19770 [file] [log] [blame]
Mihai Sardarescu160ec662018-07-18 21:13:511// Copyright 2018 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef COMPONENTS_UNIFIED_CONSENT_FEATURE_H_
6#define COMPONENTS_UNIFIED_CONSENT_FEATURE_H_
7
8#include "base/feature_list.h"
9
10namespace unified_consent {
11
12// State of the "Unified Consent" feature.
13enum class UnifiedConsentFeatureState {
14 // Unified consent is disabled.
15 kDisabled,
16 // Unified consent is enabled, but the bump is not shown.
17 kEnabledNoBump,
18 // Unified consent is enabled and the bump is shown.
19 kEnabledWithBump
20};
21
22// Improved and unified consent for privacy-related features.
23extern const base::Feature kUnifiedConsent;
24extern const char kUnifiedConsentShowBumpParameter[];
Jérôme Lebelfe1b2e02018-08-03 12:26:2025extern const base::Feature kForceUnifiedConsentBump;
Mihai Sardarescu160ec662018-07-18 21:13:5126
Mihai Sardarescu29a8cd82018-09-05 16:52:2027// Returns true if the unified consent feature state is kEnabledNoBump or
28// kEnabledWithBump. Note that the bump may not be enabled, even if this returns
29// true. To check if the bump is enabled, use
30// IsUnifiedConsentFeatureWithBumpEnabled().
31bool IsUnifiedConsentFeatureEnabled();
32
33// Returns true if the unified consent feature state is kEnabledWithBump.
34bool IsUnifiedConsentFeatureWithBumpEnabled();
Mihai Sardarescu160ec662018-07-18 21:13:5135
36} // namespace unified_consent
37
38#endif // COMPONENTS_UNIFIED_CONSENT_FEATURE_H_