OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/common/pref_names.h" | 5 #include "components/content_settings/core/common/pref_names.h" |
6 | 6 |
7 namespace prefs { | 7 namespace prefs { |
8 | 8 |
9 // Version of the pattern format used to define content settings. | 9 // Version of the pattern format used to define content settings. |
10 const char kContentSettingsVersion[] = "profile.content_settings.pref_version"; | 10 const char kContentSettingsVersion[] = "profile.content_settings.pref_version"; |
11 | 11 |
12 // Patterns for mapping origins to origin related settings. Default settings | 12 // Patterns for mapping origins to origin related settings. Default settings |
13 // will be applied to origins that don't match any of the patterns. The pattern | 13 // will be applied to origins that don't match any of the patterns. The pattern |
14 // format used is defined by kContentSettingsVersion. | 14 // format used is defined by kContentSettingsVersion. |
15 const char kContentSettingsPatternPairs[] = | 15 const char kContentSettingsPatternPairs[] = |
16 "profile.content_settings.pattern_pairs"; | 16 "profile.content_settings.pattern_pairs"; |
17 | 17 |
18 // Integer that specifies the index of the tab the user was on when they | 18 // Integer that specifies the index of the tab the user was on when they |
19 // last visited the content settings window. | 19 // last visited the content settings window. |
20 const char kContentSettingsWindowLastTabIndex[] = | 20 const char kContentSettingsWindowLastTabIndex[] = |
21 "content_settings_window.last_tab_index"; | 21 "content_settings_window.last_tab_index"; |
22 | 22 |
23 // Dictionary of content settings applied to all hosts by default. | 23 // Dictionary of content settings applied to all hosts by default. |
| 24 // TODO(msramek): Deprecated. Use the individual preferences below. |
24 const char kDefaultContentSettings[] = "profile.default_content_settings"; | 25 const char kDefaultContentSettings[] = "profile.default_content_settings"; |
25 | 26 |
| 27 // Whether |kDefaultContentSettings| has already been migrated to |
| 28 // |kDefault<type>Setting| prefs. |
| 29 const char kMigratedDefaultContentSettings[] = |
| 30 "profile.migrated_default_content_settings"; |
| 31 |
| 32 // Preferences storing the default values for individual content settings. |
| 33 const char kDefaultCookiesSetting[] = |
| 34 "profile.default_content_setting_values.cookies"; |
| 35 const char kDefaultImagesSetting[] = |
| 36 "profile.default_content_setting_values.images"; |
| 37 const char kDefaultJavaScriptSetting[] = |
| 38 "profile.default_content_setting_values.javascript"; |
| 39 const char kDefaultPluginsSetting[] = |
| 40 "profile.default_content_setting_values.plugins"; |
| 41 const char kDefaultPopupsSetting[] = |
| 42 "profile.default_content_setting_values.popups"; |
| 43 const char kDefaultGeolocationSetting[] = |
| 44 "profile.default_content_setting_values.geolocation"; |
| 45 const char kDefaultNotificationsSetting[] = |
| 46 "profile.default_content_setting_values.notifications"; |
| 47 const char kDefaultAutoSelectCertificateSetting[] = |
| 48 "profile.default_content_setting_values.auto_select_certificate"; |
| 49 const char kDefaultFullScreenSetting[] = |
| 50 "profile.default_content_setting_values.fullscreen"; |
| 51 const char kDefaultMouseLockSetting[] = |
| 52 "profile.default_content_setting_values.mouselock"; |
| 53 const char kDefaultMixedScriptSetting[] = |
| 54 "profile.default_content_setting_values.mixed_script"; |
| 55 const char kDefaultMediaStreamSetting[] = |
| 56 "profile.default_content_setting_values.media_stream"; |
| 57 const char kDefaultMediaStreamMicSetting[] = |
| 58 "profile.default_content_setting_values.media_stream_mic"; |
| 59 const char kDefaultMediaStreamCameraSetting[] = |
| 60 "profile.default_content_setting_values.media_stream_camera"; |
| 61 const char kDefaultProtocolHandlersSetting[] = |
| 62 "profile.default_content_setting_values.protocol_handlers"; |
| 63 const char kDefaultPpapiBrokerSetting[] = |
| 64 "profile.default_content_setting_values.ppapi_broker"; |
| 65 const char kDefaultAutomaticDownloadsSetting[] = |
| 66 "profile.default_content_setting_values.automatic_downloads"; |
| 67 const char kDefaultMidiSysexSetting[] = |
| 68 "profile.default_content_setting_values.midi_sysex"; |
| 69 const char kDefaultPushMessagingSetting[] = |
| 70 "profile.default_content_setting_values.push_messaging"; |
| 71 const char kDefaultSSLCertDecisionsSetting[] = |
| 72 "profile.default_content_setting_values.ssl_cert_decisions"; |
| 73 #if defined(OS_WIN) |
| 74 const char kDefaultMetroSwitchToDesktopSetting[] = |
| 75 "profile.default_content_setting_values.metro_switch_to_desktop"; |
| 76 #elif defined(OS_ANDROID) || defined(OS_CHROMEOS) |
| 77 const char kDefaultProtectedMediaIdentifierSetting[] = |
| 78 "profile.default_content_setting_values.protected_media_identifier"; |
| 79 #endif |
| 80 const char kDefaultAppBannerSetting[] = |
| 81 "profile.default_content_setting_values.app_banner"; |
| 82 |
26 // Dictionary of content settings that can globally disallow all hosts by | 83 // Dictionary of content settings that can globally disallow all hosts by |
27 // default. If a value is set, it means the setting is globally disallowed. | 84 // default. If a value is set, it means the setting is globally disallowed. |
28 // If a value is not set, it means the setting is allowed. | 85 // If a value is not set, it means the setting is allowed. |
29 const char kOverrideContentSettings[] = "profile.override_content_settings"; | 86 const char kOverrideContentSettings[] = "profile.override_content_settings"; |
30 | 87 |
31 // Preferences that are exclusively used to store managed values for default | 88 // Preferences that are exclusively used to store managed values for default |
32 // content settings. | 89 // content settings. |
33 const char kManagedDefaultCookiesSetting[] = | 90 const char kManagedDefaultCookiesSetting[] = |
34 "profile.managed_default_content_settings.cookies"; | 91 "profile.managed_default_content_settings.cookies"; |
35 const char kManagedDefaultImagesSetting[] = | 92 const char kManagedDefaultImagesSetting[] = |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 const char kManagedPopupsBlockedForUrls[] = | 129 const char kManagedPopupsBlockedForUrls[] = |
73 "profile.managed_popups_blocked_for_urls"; | 130 "profile.managed_popups_blocked_for_urls"; |
74 const char kManagedNotificationsAllowedForUrls[] = | 131 const char kManagedNotificationsAllowedForUrls[] = |
75 "profile.managed_notifications_allowed_for_urls"; | 132 "profile.managed_notifications_allowed_for_urls"; |
76 const char kManagedNotificationsBlockedForUrls[] = | 133 const char kManagedNotificationsBlockedForUrls[] = |
77 "profile.managed_notifications_blocked_for_urls"; | 134 "profile.managed_notifications_blocked_for_urls"; |
78 const char kManagedAutoSelectCertificateForUrls[] = | 135 const char kManagedAutoSelectCertificateForUrls[] = |
79 "profile.managed_auto_select_certificate_for_urls"; | 136 "profile.managed_auto_select_certificate_for_urls"; |
80 | 137 |
81 } // namespace prefs | 138 } // namespace prefs |
OLD | NEW |