| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_PLUGINS_PLUGIN_PREFS_H_ | 5 #ifndef CHROME_BROWSER_PLUGINS_PLUGIN_PREFS_H_ |
| 6 #define CHROME_BROWSER_PLUGINS_PLUGIN_PREFS_H_ | 6 #define CHROME_BROWSER_PLUGINS_PLUGIN_PREFS_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 std::map<base::FilePath, bool> state_; | 100 std::map<base::FilePath, bool> state_; |
| 101 }; | 101 }; |
| 102 | 102 |
| 103 ~PluginPrefs() override; | 103 ~PluginPrefs() override; |
| 104 | 104 |
| 105 // Called to update one of the policy_xyz patterns below when a | 105 // Called to update one of the policy_xyz patterns below when a |
| 106 // preference changes. | 106 // preference changes. |
| 107 void UpdatePatternsAndNotify(std::set<base::string16>* patterns, | 107 void UpdatePatternsAndNotify(std::set<base::string16>* patterns, |
| 108 const std::string& pref_name); | 108 const std::string& pref_name); |
| 109 | 109 |
| 110 // Called to enable NPAPI if kEnableNpapi gets set by policy. |
| 111 void EnableNpapi(); |
| 112 |
| 110 // Allows unit tests to directly set enforced plugin patterns. | 113 // Allows unit tests to directly set enforced plugin patterns. |
| 111 void SetPolicyEnforcedPluginPatterns( | 114 void SetPolicyEnforcedPluginPatterns( |
| 112 const std::set<base::string16>& disabled_patterns, | 115 const std::set<base::string16>& disabled_patterns, |
| 113 const std::set<base::string16>& disabled_exception_patterns, | 116 const std::set<base::string16>& disabled_exception_patterns, |
| 114 const std::set<base::string16>& enabled_patterns); | 117 const std::set<base::string16>& enabled_patterns); |
| 115 | 118 |
| 116 // Callback for after the plugin groups have been loaded. | 119 // Callback for after the plugin groups have been loaded. |
| 117 void EnablePluginGroupInternal( | 120 void EnablePluginGroupInternal( |
| 118 bool enabled, | 121 bool enabled, |
| 119 const base::string16& group_name, | 122 const base::string16& group_name, |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 | 156 |
| 154 // Weak pointer, owned by the profile. | 157 // Weak pointer, owned by the profile. |
| 155 PrefService* prefs_; | 158 PrefService* prefs_; |
| 156 | 159 |
| 157 PrefChangeRegistrar registrar_; | 160 PrefChangeRegistrar registrar_; |
| 158 | 161 |
| 159 DISALLOW_COPY_AND_ASSIGN(PluginPrefs); | 162 DISALLOW_COPY_AND_ASSIGN(PluginPrefs); |
| 160 }; | 163 }; |
| 161 | 164 |
| 162 #endif // CHROME_BROWSER_PLUGINS_PLUGIN_PREFS_H_ | 165 #endif // CHROME_BROWSER_PLUGINS_PLUGIN_PREFS_H_ |
| OLD | NEW |