| Index: third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp
|
| diff --git a/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp b/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp
|
| index f89c965b35075a0057e00fe885d3e977f2c26074..6e011765a44083c97aed9cbe357f0901337f0191 100644
|
| --- a/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp
|
| +++ b/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp
|
| @@ -128,13 +128,29 @@ WebParsedFeaturePolicy GetContainerPolicyFromAllowedFeatures(
|
| return whitelists;
|
| }
|
|
|
| +bool IsSupportedInFeaturePolicy(WebFeaturePolicyFeature feature) {
|
| + switch (feature) {
|
| + // TODO(lunalu): Re-enabled fullscreen in feature policy once tests have
|
| + // been updated.
|
| + // crbug.com/666761
|
| + case WebFeaturePolicyFeature::kFullscreen:
|
| + return false;
|
| + case WebFeaturePolicyFeature::kPayment:
|
| + return true;
|
| + case WebFeaturePolicyFeature::kVibrate:
|
| + return RuntimeEnabledFeatures::featurePolicyExperimentalFeaturesEnabled();
|
| + default:
|
| + return false;
|
| + }
|
| +}
|
| +
|
| const FeatureNameMap& GetDefaultFeatureNameMap() {
|
| DEFINE_STATIC_LOCAL(FeatureNameMap, default_feature_name_map, ());
|
| if (default_feature_name_map.IsEmpty()) {
|
| - default_feature_name_map.Set("fullscreen",
|
| - WebFeaturePolicyFeature::kFullscreen);
|
| default_feature_name_map.Set("payment", WebFeaturePolicyFeature::kPayment);
|
| if (RuntimeEnabledFeatures::featurePolicyExperimentalFeaturesEnabled()) {
|
| + default_feature_name_map.Set("fullscreen",
|
| + WebFeaturePolicyFeature::kFullscreen);
|
| default_feature_name_map.Set("vibrate",
|
| WebFeaturePolicyFeature::kVibrate);
|
| default_feature_name_map.Set("camera", WebFeaturePolicyFeature::kCamera);
|
|
|