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

Side by Side Diff: ios/chrome/browser/experimental_flags.mm

Issue 2386143004: Upstream method to check if MDM integration support is enabled. (Closed)
Patch Set: Created 4 years, 2 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
« no previous file with comments | « ios/chrome/browser/experimental_flags.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // This file can be empty. Its purpose is to contain the relatively short lived 5 // This file can be empty. Its purpose is to contain the relatively short lived
6 // definitions required for experimental flags. 6 // definitions required for experimental flags.
7 7
8 #include "ios/chrome/browser/experimental_flags.h" 8 #include "ios/chrome/browser/experimental_flags.h"
9 9
10 #include <dispatch/dispatch.h> 10 #include <dispatch/dispatch.h>
(...skipping 11 matching lines...) Expand all
22 22
23 namespace { 23 namespace {
24 NSString* const kEnableAlertOnBackgroundUpload = 24 NSString* const kEnableAlertOnBackgroundUpload =
25 @"EnableAlertsOnBackgroundUpload"; 25 @"EnableAlertsOnBackgroundUpload";
26 NSString* const kEnableViewCopyPasswords = @"EnableViewCopyPasswords"; 26 NSString* const kEnableViewCopyPasswords = @"EnableViewCopyPasswords";
27 NSString* const kHeuristicsForPasswordGeneration = 27 NSString* const kHeuristicsForPasswordGeneration =
28 @"HeuristicsForPasswordGeneration"; 28 @"HeuristicsForPasswordGeneration";
29 NSString* const kEnableReadingList = @"EnableReadingList"; 29 NSString* const kEnableReadingList = @"EnableReadingList";
30 NSString* const kUpdatePasswordUIDisabled = @"UpdatePasswordUIDisabled"; 30 NSString* const kUpdatePasswordUIDisabled = @"UpdatePasswordUIDisabled";
31 NSString* const kEnableNewClearBrowsingDataUI = @"EnableNewClearBrowsingDataUI"; 31 NSString* const kEnableNewClearBrowsingDataUI = @"EnableNewClearBrowsingDataUI";
32 NSString* const kMDMIntegrationDisabled = @"MDMIntegrationDisabled";
32 } // namespace 33 } // namespace
33 34
34 namespace experimental_flags { 35 namespace experimental_flags {
35 36
36 bool IsAlertOnBackgroundUploadEnabled() { 37 bool IsAlertOnBackgroundUploadEnabled() {
37 return [[NSUserDefaults standardUserDefaults] 38 return [[NSUserDefaults standardUserDefaults]
38 boolForKey:kEnableAlertOnBackgroundUpload]; 39 boolForKey:kEnableAlertOnBackgroundUpload];
39 } 40 }
40 41
41 bool IsLRUSnapshotCacheEnabled() { 42 bool IsLRUSnapshotCacheEnabled() {
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 // Check if the Finch experiment is turned on. 174 // Check if the Finch experiment is turned on.
174 return base::StartsWith(group_name, "Enabled", 175 return base::StartsWith(group_name, "Enabled",
175 base::CompareCase::INSENSITIVE_ASCII); 176 base::CompareCase::INSENSITIVE_ASCII);
176 } 177 }
177 178
178 bool IsSpotlightActionsEnabled() { 179 bool IsSpotlightActionsEnabled() {
179 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 180 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
180 return !command_line->HasSwitch(switches::kDisableSpotlightActions); 181 return !command_line->HasSwitch(switches::kDisableSpotlightActions);
181 } 182 }
182 183
184 bool IsMDMIntegrationEnabled() {
185 return ![[NSUserDefaults standardUserDefaults]
186 boolForKey:kMDMIntegrationDisabled];
187 }
188
183 } // namespace experimental_flags 189 } // namespace experimental_flags
OLDNEW
« no previous file with comments | « ios/chrome/browser/experimental_flags.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698