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 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
351 type, name, std::move(default_value), sync_status, | 351 type, name, std::move(default_value), sync_status, |
352 WebsiteSettingsInfo::NOT_LOSSY, scoping_type, platforms, | 352 WebsiteSettingsInfo::NOT_LOSSY, scoping_type, platforms, |
353 WebsiteSettingsInfo::INHERIT_IN_INCOGNITO); | 353 WebsiteSettingsInfo::INHERIT_IN_INCOGNITO); |
354 | 354 |
355 // WebsiteSettingsInfo::Register() will return nullptr if content setting type | 355 // WebsiteSettingsInfo::Register() will return nullptr if content setting type |
356 // is not used on the current platform and doesn't need to be registered. | 356 // is not used on the current platform and doesn't need to be registered. |
357 if (!website_settings_info) | 357 if (!website_settings_info) |
358 return; | 358 return; |
359 | 359 |
360 DCHECK(!base::ContainsKey(content_settings_info_, type)); | 360 DCHECK(!base::ContainsKey(content_settings_info_, type)); |
361 content_settings_info_[type] = base::WrapUnique( | 361 content_settings_info_[type] = base::MakeUnique<ContentSettingsInfo>( |
362 new ContentSettingsInfo(website_settings_info, whitelisted_schemes, | 362 website_settings_info, whitelisted_schemes, valid_settings, |
363 valid_settings, incognito_behavior)); | 363 incognito_behavior); |
364 } | 364 } |
365 | 365 |
366 } // namespace content_settings | 366 } // namespace content_settings |
OLD | NEW |