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

Side by Side Diff: components/content_settings/core/browser/plugins_field_trial.h

Issue 1084123002: Make DETECT_IMPORTANT_CONTENT the default Plugins content setting based (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: gyp shuffle for ios Created 5 years, 8 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 #ifndef CHROME_BROWSER_PLUGINS_PLUGINS_FIELD_TRIAL_H_ 5 #ifndef COMPONENTS_CONTENT_SETTINGS_CORE_BROWSER_CONTENT_SETTINGS_H_
6 #define CHROME_BROWSER_PLUGINS_PLUGINS_FIELD_TRIAL_H_ 6 #define COMPONENTS_CONTENT_SETTINGS_CORE_BROWSER_CONTENT_SETTINGS_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "components/content_settings/core/common/content_settings.h" 9 #include "components/content_settings/core/common/content_settings.h"
10 #include "components/content_settings/core/common/content_settings_types.h" 10 #include "components/content_settings/core/common/content_settings_types.h"
11 11
12 namespace content_settings {
13
12 // This class manages the Plugins field trials. 14 // This class manages the Plugins field trials.
13 class PluginsFieldTrial { 15 class PluginsFieldTrial {
14 public: 16 public:
17 static const char kFieldTrialName[];
18
15 // Returns the effective content setting for plugins. Passes non-plugin 19 // Returns the effective content setting for plugins. Passes non-plugin
16 // content settings through without modification. 20 // content settings through without modification.
17 static ContentSetting EffectiveContentSetting(ContentSettingsType type, 21 static ContentSetting EffectiveContentSetting(ContentSettingsType type,
18 ContentSetting setting); 22 ContentSetting setting);
19 23
20 // Returns true if the Plugin Power Saver feature is forced on, overriding 24 // Returns true if the Plugin Power Saver feature is enabled.
21 // the user's Content Settings. 25 static bool IsPluginPowerSaverEnabled();
22 static bool IsForcePluginPowerSaverEnabled(); 26
27 // Get the default plugins content setting based on field trials/flags.
28 static ContentSetting GetDefaultPluginsContentSetting();
23 29
24 private: 30 private:
25 DISALLOW_IMPLICIT_CONSTRUCTORS(PluginsFieldTrial); 31 DISALLOW_IMPLICIT_CONSTRUCTORS(PluginsFieldTrial);
26 }; 32 };
27 33
28 #endif // CHROME_BROWSER_PLUGINS_PLUGINS_FIELD_TRIAL_H_ 34 } // namespace content_settings
35
36 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_BROWSER_CONTENT_SETTINGS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698