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

Side by Side Diff: components/content_settings/core/browser/content_settings_registry.cc

Issue 2123863004: ScreenCapture for Android phase1, part II (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase to #407492(Jul 25) Created 4 years, 4 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 unified diff | Download patch
OLDNEW
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 317 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 ContentSettingsInfo::INHERIT_IN_INCOGNITO); 328 ContentSettingsInfo::INHERIT_IN_INCOGNITO);
329 329
330 Register(CONTENT_SETTINGS_TYPE_BLUETOOTH_GUARD, "bluetooth-guard", 330 Register(CONTENT_SETTINGS_TYPE_BLUETOOTH_GUARD, "bluetooth-guard",
331 CONTENT_SETTING_ASK, WebsiteSettingsInfo::UNSYNCABLE, 331 CONTENT_SETTING_ASK, WebsiteSettingsInfo::UNSYNCABLE,
332 WhitelistedSchemes(), 332 WhitelistedSchemes(),
333 ValidSettings(CONTENT_SETTING_ASK, CONTENT_SETTING_BLOCK), 333 ValidSettings(CONTENT_SETTING_ASK, CONTENT_SETTING_BLOCK),
334 WebsiteSettingsInfo::REQUESTING_ORIGIN_AND_TOP_LEVEL_ORIGIN_SCOPE, 334 WebsiteSettingsInfo::REQUESTING_ORIGIN_AND_TOP_LEVEL_ORIGIN_SCOPE,
335 WebsiteSettingsRegistry::DESKTOP | 335 WebsiteSettingsRegistry::DESKTOP |
336 WebsiteSettingsRegistry::PLATFORM_ANDROID, 336 WebsiteSettingsRegistry::PLATFORM_ANDROID,
337 ContentSettingsInfo::INHERIT_IN_INCOGNITO); 337 ContentSettingsInfo::INHERIT_IN_INCOGNITO);
338
339 Register(CONTENT_SETTINGS_TYPE_MEDIASTREAM_SCREEN, "media-stream-screen",
Sergey Ulanov 2016/08/01 18:20:36 Do we need to register it when the feature is not
braveyao 2016/08/03 00:23:47 This setting is invisible to users. Should be OK.
340 CONTENT_SETTING_DEFAULT, WebsiteSettingsInfo::UNSYNCABLE,
341 WhitelistedSchemes(), ValidSettings(),
342 WebsiteSettingsInfo::REQUESTING_ORIGIN_ONLY_SCOPE,
343 WebsiteSettingsRegistry::PLATFORM_ANDROID,
344 ContentSettingsInfo::INHERIT_IN_INCOGNITO);
338 } 345 }
339 346
340 void ContentSettingsRegistry::Register( 347 void ContentSettingsRegistry::Register(
341 ContentSettingsType type, 348 ContentSettingsType type,
342 const std::string& name, 349 const std::string& name,
343 ContentSetting initial_default_value, 350 ContentSetting initial_default_value,
344 WebsiteSettingsInfo::SyncStatus sync_status, 351 WebsiteSettingsInfo::SyncStatus sync_status,
345 const std::vector<std::string>& whitelisted_schemes, 352 const std::vector<std::string>& whitelisted_schemes,
346 const std::set<ContentSetting>& valid_settings, 353 const std::set<ContentSetting>& valid_settings,
347 WebsiteSettingsInfo::ScopingType scoping_type, 354 WebsiteSettingsInfo::ScopingType scoping_type,
(...skipping 19 matching lines...) Expand all
367 if (!website_settings_info) 374 if (!website_settings_info)
368 return; 375 return;
369 376
370 DCHECK(!ContainsKey(content_settings_info_, type)); 377 DCHECK(!ContainsKey(content_settings_info_, type));
371 content_settings_info_[type] = base::WrapUnique( 378 content_settings_info_[type] = base::WrapUnique(
372 new ContentSettingsInfo(website_settings_info, whitelisted_schemes, 379 new ContentSettingsInfo(website_settings_info, whitelisted_schemes,
373 valid_settings, incognito_behavior)); 380 valid_settings, incognito_behavior));
374 } 381 }
375 382
376 } // namespace content_settings 383 } // namespace content_settings
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698