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

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

Issue 2355743004: Enable Spotlight Actions by default. (Closed)
Patch Set: Fix compilation error. Created 4 years, 3 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 | « no previous file | ios/chrome/browser/experimental_flags.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 // Implementation of about_flags for iOS that sets flags based on experimental 5 // Implementation of about_flags for iOS that sets flags based on experimental
6 // settings. 6 // settings.
7 7
8 #include "ios/chrome/browser/about_flags.h" 8 #include "ios/chrome/browser/about_flags.h"
9 9
10 #include <stddef.h> 10 #include <stddef.h>
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 // Populate command line flag for the Payment Request API. 201 // Populate command line flag for the Payment Request API.
202 NSString* enable_payment_request = 202 NSString* enable_payment_request =
203 [defaults stringForKey:@"EnablePaymentRequest"]; 203 [defaults stringForKey:@"EnablePaymentRequest"];
204 if ([enable_payment_request isEqualToString:@"Enabled"]) { 204 if ([enable_payment_request isEqualToString:@"Enabled"]) {
205 command_line->AppendSwitch(switches::kEnablePaymentRequest); 205 command_line->AppendSwitch(switches::kEnablePaymentRequest);
206 } else if ([enable_payment_request isEqualToString:@"Disabled"]) { 206 } else if ([enable_payment_request isEqualToString:@"Disabled"]) {
207 command_line->AppendSwitch(switches::kDisablePaymentRequest); 207 command_line->AppendSwitch(switches::kDisablePaymentRequest);
208 } 208 }
209 209
210 // Populate command line flag for Spotlight Actions. 210 // Populate command line flag for Spotlight Actions.
211 NSString* enableSpotlightActions = 211 if ([defaults boolForKey:@"DisableSpotlightActions"]) {
212 [defaults stringForKey:@"EnableSpotlightActions"];
213 if ([enableSpotlightActions isEqualToString:@"Enabled"]) {
214 command_line->AppendSwitch(switches::kEnableSpotlightActions);
215 } else if ([enableSpotlightActions isEqualToString:@"Disabled"]) {
216 command_line->AppendSwitch(switches::kDisableSpotlightActions); 212 command_line->AppendSwitch(switches::kDisableSpotlightActions);
217 } 213 }
218 214
219 // Freeform commandline flags. These are added last, so that any flags added 215 // Freeform commandline flags. These are added last, so that any flags added
220 // earlier in this function take precedence. 216 // earlier in this function take precedence.
221 if ([defaults boolForKey:@"EnableFreeformCommandLineFlags"]) { 217 if ([defaults boolForKey:@"EnableFreeformCommandLineFlags"]) {
222 base::CommandLine::StringVector flags; 218 base::CommandLine::StringVector flags;
223 // Append an empty "program" argument. 219 // Append an empty "program" argument.
224 flags.push_back(""); 220 flags.push_back("");
225 221
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 } 297 }
302 298
303 namespace testing { 299 namespace testing {
304 300
305 const flags_ui::FeatureEntry* GetFeatureEntries(size_t* count) { 301 const flags_ui::FeatureEntry* GetFeatureEntries(size_t* count) {
306 *count = arraysize(kFeatureEntries); 302 *count = arraysize(kFeatureEntries);
307 return kFeatureEntries; 303 return kFeatureEntries;
308 } 304 }
309 305
310 } // namespace testing 306 } // namespace testing
OLDNEW
« no previous file with comments | « no previous file | ios/chrome/browser/experimental_flags.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698