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

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

Issue 579673003: Move content_settings_observer.h, content_settings_provider.h, content_settings_rule.* to the compo… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: last comment Created 6 years, 3 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 (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
11 #include "base/bind.h" 11 #include "base/bind.h"
12 #include "base/bind_helpers.h" 12 #include "base/bind_helpers.h"
13 #include "base/command_line.h" 13 #include "base/command_line.h"
14 #include "base/prefs/pref_service.h" 14 #include "base/prefs/pref_service.h"
15 #include "base/strings/string_number_conversions.h" 15 #include "base/strings/string_number_conversions.h"
16 #include "base/strings/utf_string_conversions.h" 16 #include "base/strings/utf_string_conversions.h"
17 #include "base/values.h" 17 #include "base/values.h"
18 #include "chrome/browser/browser_process.h" 18 #include "chrome/browser/browser_process.h"
19 #include "chrome/browser/chrome_notification_types.h" 19 #include "chrome/browser/chrome_notification_types.h"
20 #include "chrome/browser/content_settings/content_settings_details.h"
21 #include "chrome/browser/content_settings/content_settings_provider.h"
22 #include "chrome/browser/content_settings/content_settings_utils.h" 20 #include "chrome/browser/content_settings/content_settings_utils.h"
23 #include "chrome/browser/content_settings/host_content_settings_map.h" 21 #include "chrome/browser/content_settings/host_content_settings_map.h"
24 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" 22 #include "chrome/browser/custom_handlers/protocol_handler_registry.h"
25 #include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h" 23 #include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h"
26 #include "chrome/browser/extensions/extension_special_storage_policy.h" 24 #include "chrome/browser/extensions/extension_special_storage_policy.h"
27 #include "chrome/browser/notifications/desktop_notification_profile_util.h" 25 #include "chrome/browser/notifications/desktop_notification_profile_util.h"
28 #include "chrome/browser/profiles/profile.h" 26 #include "chrome/browser/profiles/profile.h"
29 #include "chrome/browser/ui/browser_list.h" 27 #include "chrome/browser/ui/browser_list.h"
30 #include "chrome/common/chrome_switches.h" 28 #include "chrome/common/chrome_switches.h"
31 #include "chrome/common/extensions/manifest_handlers/app_launch_info.h" 29 #include "chrome/common/extensions/manifest_handlers/app_launch_info.h"
32 #include "chrome/common/pref_names.h" 30 #include "chrome/common/pref_names.h"
33 #include "chrome/common/url_constants.h" 31 #include "chrome/common/url_constants.h"
34 #include "chrome/grit/generated_resources.h" 32 #include "chrome/grit/generated_resources.h"
35 #include "chrome/grit/locale_settings.h" 33 #include "chrome/grit/locale_settings.h"
34 #include "components/content_settings/core/browser/content_settings_details.h"
36 #include "components/content_settings/core/common/content_settings.h" 35 #include "components/content_settings/core/common/content_settings.h"
37 #include "components/content_settings/core/common/content_settings_pattern.h" 36 #include "components/content_settings/core/common/content_settings_pattern.h"
38 #include "components/google/core/browser/google_util.h" 37 #include "components/google/core/browser/google_util.h"
39 #include "components/user_prefs/user_prefs.h" 38 #include "components/user_prefs/user_prefs.h"
40 #include "content/public/browser/notification_service.h" 39 #include "content/public/browser/notification_service.h"
41 #include "content/public/browser/notification_source.h" 40 #include "content/public/browser/notification_source.h"
42 #include "content/public/browser/notification_types.h" 41 #include "content/public/browser/notification_types.h"
43 #include "content/public/browser/user_metrics.h" 42 #include "content/public/browser/user_metrics.h"
44 #include "content/public/browser/web_contents.h" 43 #include "content/public/browser/web_contents.h"
45 #include "content/public/browser/web_ui.h" 44 #include "content/public/browser/web_ui.h"
(...skipping 1447 matching lines...) Expand 10 before | Expand all | Expand 10 after
1493 void ContentSettingsHandler::UpdateProtectedContentExceptionsButton() { 1492 void ContentSettingsHandler::UpdateProtectedContentExceptionsButton() {
1494 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui())); 1493 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui()));
1495 // Exceptions apply only when the feature is enabled. 1494 // Exceptions apply only when the feature is enabled.
1496 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM); 1495 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM);
1497 web_ui()->CallJavascriptFunction( 1496 web_ui()->CallJavascriptFunction(
1498 "ContentSettings.enableProtectedContentExceptions", 1497 "ContentSettings.enableProtectedContentExceptions",
1499 base::FundamentalValue(enable_exceptions)); 1498 base::FundamentalValue(enable_exceptions));
1500 } 1499 }
1501 1500
1502 } // namespace options 1501 } // namespace options
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/options/content_settings_handler.h ('k') | chrome/browser/ui/webui/options/website_settings_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698