OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "components/content_settings/core/browser/content_settings_registry.h" | 5 #include "components/content_settings/core/browser/content_settings_registry.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 | 259 |
260 Register(CONTENT_SETTINGS_TYPE_BACKGROUND_SYNC, "background-sync", | 260 Register(CONTENT_SETTINGS_TYPE_BACKGROUND_SYNC, "background-sync", |
261 CONTENT_SETTING_ALLOW, WebsiteSettingsInfo::UNSYNCABLE, | 261 CONTENT_SETTING_ALLOW, WebsiteSettingsInfo::UNSYNCABLE, |
262 WhitelistedSchemes(), | 262 WhitelistedSchemes(), |
263 ValidSettings(CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK), | 263 ValidSettings(CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK), |
264 WebsiteSettingsInfo::REQUESTING_ORIGIN_ONLY_SCOPE, | 264 WebsiteSettingsInfo::REQUESTING_ORIGIN_ONLY_SCOPE, |
265 WebsiteSettingsRegistry::DESKTOP | | 265 WebsiteSettingsRegistry::DESKTOP | |
266 WebsiteSettingsRegistry::PLATFORM_ANDROID, | 266 WebsiteSettingsRegistry::PLATFORM_ANDROID, |
267 ContentSettingsInfo::INHERIT_IF_LESS_PERMISSIVE); | 267 ContentSettingsInfo::INHERIT_IF_LESS_PERMISSIVE); |
268 | 268 |
| 269 Register(CONTENT_SETTINGS_TYPE_PAYMENT_HANDLER, "payment-handler", |
| 270 CONTENT_SETTING_ASK, WebsiteSettingsInfo::UNSYNCABLE, |
| 271 WhitelistedSchemes(), |
| 272 ValidSettings(CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK, |
| 273 CONTENT_SETTING_ASK), |
| 274 WebsiteSettingsInfo::REQUESTING_ORIGIN_AND_TOP_LEVEL_ORIGIN_SCOPE, |
| 275 WebsiteSettingsRegistry::DESKTOP | |
| 276 WebsiteSettingsRegistry::PLATFORM_ANDROID, |
| 277 ContentSettingsInfo::INHERIT_IF_LESS_PERMISSIVE); |
| 278 |
269 Register(CONTENT_SETTINGS_TYPE_AUTOPLAY, "autoplay", CONTENT_SETTING_ALLOW, | 279 Register(CONTENT_SETTINGS_TYPE_AUTOPLAY, "autoplay", CONTENT_SETTING_ALLOW, |
270 WebsiteSettingsInfo::UNSYNCABLE, WhitelistedSchemes(), | 280 WebsiteSettingsInfo::UNSYNCABLE, WhitelistedSchemes(), |
271 ValidSettings(CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK), | 281 ValidSettings(CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK), |
272 WebsiteSettingsInfo::REQUESTING_ORIGIN_ONLY_SCOPE, | 282 WebsiteSettingsInfo::REQUESTING_ORIGIN_ONLY_SCOPE, |
273 WebsiteSettingsRegistry::DESKTOP | | 283 WebsiteSettingsRegistry::DESKTOP | |
274 WebsiteSettingsRegistry::PLATFORM_ANDROID, | 284 WebsiteSettingsRegistry::PLATFORM_ANDROID, |
275 ContentSettingsInfo::INHERIT_IF_LESS_PERMISSIVE); | 285 ContentSettingsInfo::INHERIT_IF_LESS_PERMISSIVE); |
276 | 286 |
277 Register(CONTENT_SETTINGS_TYPE_ADS, "subresource-filter", | 287 Register(CONTENT_SETTINGS_TYPE_ADS, "subresource-filter", |
278 CONTENT_SETTING_BLOCK, WebsiteSettingsInfo::UNSYNCABLE, | 288 CONTENT_SETTING_BLOCK, WebsiteSettingsInfo::UNSYNCABLE, |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
336 if (!website_settings_info) | 346 if (!website_settings_info) |
337 return; | 347 return; |
338 | 348 |
339 DCHECK(!base::ContainsKey(content_settings_info_, type)); | 349 DCHECK(!base::ContainsKey(content_settings_info_, type)); |
340 content_settings_info_[type] = base::MakeUnique<ContentSettingsInfo>( | 350 content_settings_info_[type] = base::MakeUnique<ContentSettingsInfo>( |
341 website_settings_info, whitelisted_schemes, valid_settings, | 351 website_settings_info, whitelisted_schemes, valid_settings, |
342 incognito_behavior); | 352 incognito_behavior); |
343 } | 353 } |
344 | 354 |
345 } // namespace content_settings | 355 } // namespace content_settings |
OLD | NEW |