| 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 #ifndef IOS_CHROME_BROWSER_EXPERIMENTAL_FLAGS_H_ | 5 #ifndef IOS_CHROME_BROWSER_EXPERIMENTAL_FLAGS_H_ |
| 6 #define IOS_CHROME_BROWSER_EXPERIMENTAL_FLAGS_H_ | 6 #define IOS_CHROME_BROWSER_EXPERIMENTAL_FLAGS_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 // This file can be empty. Its purpose is to contain the relatively short lived | 10 // This file can be empty. Its purpose is to contain the relatively short lived |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 // Sets whether or not the field trial for WKWebView should be enabled. This | 21 // Sets whether or not the field trial for WKWebView should be enabled. This |
| 22 // must be called at most once, and before IsWKWebViewEnabled. If this is never | 22 // must be called at most once, and before IsWKWebViewEnabled. If this is never |
| 23 // called, IsWKWebViewEnabled will assume ineligibility. | 23 // called, IsWKWebViewEnabled will assume ineligibility. |
| 24 // Note that an explicit command line flag will ignore this setting; it controls | 24 // Note that an explicit command line flag will ignore this setting; it controls |
| 25 // only whether the trial state will be checked in the default state. | 25 // only whether the trial state will be checked in the default state. |
| 26 void SetWKWebViewTrialEligibility(bool eligible); | 26 void SetWKWebViewTrialEligibility(bool eligible); |
| 27 | 27 |
| 28 // Whether the lru snapshot cache experiment is enabled. | 28 // Whether the lru snapshot cache experiment is enabled. |
| 29 bool IsLRUSnapshotCacheEnabled(); | 29 bool IsLRUSnapshotCacheEnabled(); |
| 30 | 30 |
| 31 // Whether the app uses WKWebView instead of UIWebView. | 31 // TODO(crbug.com/579697): This always returns true; cleanup codepaths that use |
| 32 // The returned value will not change within a given session. | 32 // this. |
| 33 bool IsWKWebViewEnabled(); | 33 bool IsWKWebViewEnabled(); |
| 34 | 34 |
| 35 // Whether the user would be put into a control group for the WKWebView | 35 // Whether the user would be put into a control group for the WKWebView |
| 36 // experiment assuming they were eligible. Calling this will *not* activate a | 36 // experiment assuming they were eligible. Calling this will *not* activate a |
| 37 // trial, so is safe to call without checking eligibility. | 37 // trial, so is safe to call without checking eligibility. |
| 38 bool IsTargetedToWKWebViewExperimentControlGroup(); | 38 bool IsTargetedToWKWebViewExperimentControlGroup(); |
| 39 | 39 |
| 40 // Whether the user is part of a control group for the WKWebView experiment. | 40 // Whether the user is part of a control group for the WKWebView experiment. |
| 41 bool IsInWKWebViewExperimentControlGroup(); | 41 bool IsInWKWebViewExperimentControlGroup(); |
| 42 | 42 |
| 43 // Whether viewing and copying passwords is enabled. | 43 // Whether viewing and copying passwords is enabled. |
| 44 bool IsViewCopyPasswordsEnabled(); | 44 bool IsViewCopyPasswordsEnabled(); |
| 45 | 45 |
| 46 // Whether password generation is enabled. | 46 // Whether password generation is enabled. |
| 47 bool IsPasswordGenerationEnabled(); | 47 bool IsPasswordGenerationEnabled(); |
| 48 | 48 |
| 49 // Whether password generation fields are determined using local heuristics | 49 // Whether password generation fields are determined using local heuristics |
| 50 // only. | 50 // only. |
| 51 bool UseOnlyLocalHeuristicsForPasswordGeneration(); | 51 bool UseOnlyLocalHeuristicsForPasswordGeneration(); |
| 52 | 52 |
| 53 // Whether the Tab Switcher is enabled for iPad or not. | 53 // Whether the Tab Switcher is enabled for iPad or not. |
| 54 bool IsTabSwitcherEnabled(); | 54 bool IsTabSwitcherEnabled(); |
| 55 | 55 |
| 56 } // namespace experimental_flags | 56 } // namespace experimental_flags |
| 57 | 57 |
| 58 #endif // IOS_CHROME_BROWSER_EXPERIMENTAL_FLAGS_H_ | 58 #endif // IOS_CHROME_BROWSER_EXPERIMENTAL_FLAGS_H_ |
| OLD | NEW |