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

Side by Side Diff: chrome/browser/ui/webui/options/content_settings_handler.cc

Issue 1458653002: New build flag system, convert Google Now flag (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/webui/options/options_ui.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/ui/webui/options/content_settings_handler.h" 5 #include "chrome/browser/ui/webui/options/content_settings_handler.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 11 matching lines...) Expand all
22 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" 22 #include "chrome/browser/content_settings/host_content_settings_map_factory.h"
23 #include "chrome/browser/content_settings/web_site_settings_uma_util.h" 23 #include "chrome/browser/content_settings/web_site_settings_uma_util.h"
24 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" 24 #include "chrome/browser/custom_handlers/protocol_handler_registry.h"
25 #include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h" 25 #include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h"
26 #include "chrome/browser/extensions/extension_special_storage_policy.h" 26 #include "chrome/browser/extensions/extension_special_storage_policy.h"
27 #include "chrome/browser/notifications/desktop_notification_profile_util.h" 27 #include "chrome/browser/notifications/desktop_notification_profile_util.h"
28 #include "chrome/browser/profiles/profile.h" 28 #include "chrome/browser/profiles/profile.h"
29 #include "chrome/browser/ui/browser_list.h" 29 #include "chrome/browser/ui/browser_list.h"
30 #include "chrome/common/chrome_switches.h" 30 #include "chrome/common/chrome_switches.h"
31 #include "chrome/common/extensions/manifest_handlers/app_launch_info.h" 31 #include "chrome/common/extensions/manifest_handlers/app_launch_info.h"
32 #include "chrome/common/features.h"
32 #include "chrome/common/pref_names.h" 33 #include "chrome/common/pref_names.h"
33 #include "chrome/common/url_constants.h" 34 #include "chrome/common/url_constants.h"
34 #include "chrome/grit/generated_resources.h" 35 #include "chrome/grit/generated_resources.h"
35 #include "chrome/grit/locale_settings.h" 36 #include "chrome/grit/locale_settings.h"
36 #include "components/content_settings/core/browser/content_settings_details.h" 37 #include "components/content_settings/core/browser/content_settings_details.h"
37 #include "components/content_settings/core/browser/content_settings_utils.h" 38 #include "components/content_settings/core/browser/content_settings_utils.h"
38 #include "components/content_settings/core/browser/host_content_settings_map.h" 39 #include "components/content_settings/core/browser/host_content_settings_map.h"
39 #include "components/content_settings/core/browser/plugins_field_trial.h" 40 #include "components/content_settings/core/browser/plugins_field_trial.h"
40 #include "components/content_settings/core/browser/website_settings_info.h" 41 #include "components/content_settings/core/browser/website_settings_info.h"
41 #include "components/content_settings/core/browser/website_settings_registry.h" 42 #include "components/content_settings/core/browser/website_settings_registry.h"
(...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 // Cookies filter. 445 // Cookies filter.
445 {"cookiesTabLabel", IDS_COOKIES_TAB_LABEL}, 446 {"cookiesTabLabel", IDS_COOKIES_TAB_LABEL},
446 {"cookiesHeader", IDS_COOKIES_HEADER}, 447 {"cookiesHeader", IDS_COOKIES_HEADER},
447 {"cookiesAllow", IDS_COOKIES_ALLOW_RADIO}, 448 {"cookiesAllow", IDS_COOKIES_ALLOW_RADIO},
448 {"cookiesBlock", IDS_COOKIES_BLOCK_RADIO}, 449 {"cookiesBlock", IDS_COOKIES_BLOCK_RADIO},
449 {"cookiesSessionOnly", IDS_COOKIES_SESSION_ONLY_RADIO}, 450 {"cookiesSessionOnly", IDS_COOKIES_SESSION_ONLY_RADIO},
450 {"cookiesBlock3rdParty", IDS_COOKIES_BLOCK_3RDPARTY_CHKBOX}, 451 {"cookiesBlock3rdParty", IDS_COOKIES_BLOCK_3RDPARTY_CHKBOX},
451 {"cookiesShowCookies", IDS_COOKIES_SHOW_COOKIES_BUTTON}, 452 {"cookiesShowCookies", IDS_COOKIES_SHOW_COOKIES_BUTTON},
452 {"flashStorageSettings", IDS_FLASH_STORAGE_SETTINGS}, 453 {"flashStorageSettings", IDS_FLASH_STORAGE_SETTINGS},
453 {"flashStorageUrl", IDS_FLASH_STORAGE_URL}, 454 {"flashStorageUrl", IDS_FLASH_STORAGE_URL},
454 #if defined(ENABLE_GOOGLE_NOW) 455 #if BUILDFLAG(ENABLE_GOOGLE_NOW)
455 {"googleGeolocationAccessEnable", 456 {"googleGeolocationAccessEnable",
456 IDS_GEOLOCATION_GOOGLE_ACCESS_ENABLE_CHKBOX}, 457 IDS_GEOLOCATION_GOOGLE_ACCESS_ENABLE_CHKBOX},
457 #endif 458 #endif
458 // Image filter. 459 // Image filter.
459 {"imagesTabLabel", IDS_IMAGES_TAB_LABEL}, 460 {"imagesTabLabel", IDS_IMAGES_TAB_LABEL},
460 {"imagesHeader", IDS_IMAGES_HEADER}, 461 {"imagesHeader", IDS_IMAGES_HEADER},
461 {"imagesAllow", IDS_IMAGES_LOAD_RADIO}, 462 {"imagesAllow", IDS_IMAGES_LOAD_RADIO},
462 {"imagesBlock", IDS_IMAGES_NOLOAD_RADIO}, 463 {"imagesBlock", IDS_IMAGES_NOLOAD_RADIO},
463 // JavaScript filter. 464 // JavaScript filter.
464 {"javascriptTabLabel", IDS_JAVASCRIPT_TAB_LABEL}, 465 {"javascriptTabLabel", IDS_JAVASCRIPT_TAB_LABEL},
(...skipping 1214 matching lines...) Expand 10 before | Expand all | Expand 10 after
1679 1680
1680 // Exceptions apply only when the feature is enabled. 1681 // Exceptions apply only when the feature is enabled.
1681 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui())); 1682 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui()));
1682 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM); 1683 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM);
1683 web_ui()->CallJavascriptFunction( 1684 web_ui()->CallJavascriptFunction(
1684 "ContentSettings.enableProtectedContentExceptions", 1685 "ContentSettings.enableProtectedContentExceptions",
1685 base::FundamentalValue(enable_exceptions)); 1686 base::FundamentalValue(enable_exceptions));
1686 } 1687 }
1687 1688
1688 } // namespace options 1689 } // namespace options
OLDNEW
« no previous file with comments | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/webui/options/options_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698