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

Unified Diff: ios/chrome/app/spotlight/actions_spotlight_manager.mm

Issue 2676803002: Remove the iOS QR Code scanner experiment code. (Closed)
Patch Set: Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: ios/chrome/app/spotlight/actions_spotlight_manager.mm
diff --git a/ios/chrome/app/spotlight/actions_spotlight_manager.mm b/ios/chrome/app/spotlight/actions_spotlight_manager.mm
index e26959dbe8bb5c7f5dc0aedfbddfbdb3c7b959ea..ea8099f06b5bef7bd0d3424eea32d0a9f3a3bf2a 100644
--- a/ios/chrome/app/spotlight/actions_spotlight_manager.mm
+++ b/ios/chrome/app/spotlight/actions_spotlight_manager.mm
@@ -160,25 +160,19 @@ BOOL SetStartupParametersForSpotlightAction(
NSString* incognitoAction = base::SysUTF8ToNSString(
spotlight::kSpotlightActionNewIncognitoTab);
- NSMutableArray* spotlightItems = [NSMutableArray
- arrayWithObjects:[strongSelf getItemForAction:voiceSearchAction
- title:voiceSearchTitle],
- [strongSelf getItemForAction:newTabAction
- title:newTabTitle],
- [strongSelf getItemForAction:incognitoAction
- title:incognitoTitle],
- nil];
-
- if (experimental_flags::IsQRCodeReaderEnabled()) {
- NSString* qrScannerTitle = l10n_util::GetNSString(
- IDS_IOS_APPLICATION_SHORTCUT_QR_SCANNER_TITLE);
- NSString* qrScannerAction =
- base::SysUTF8ToNSString(spotlight::kSpotlightActionQRScanner);
-
- [spotlightItems
- addObject:[strongSelf getItemForAction:qrScannerAction
- title:qrScannerTitle]];
- }
+ NSString* qrScannerTitle = l10n_util::GetNSString(
+ IDS_IOS_APPLICATION_SHORTCUT_QR_SCANNER_TITLE);
+ NSString* qrScannerAction =
+ base::SysUTF8ToNSString(spotlight::kSpotlightActionQRScanner);
+
+ NSArray* spotlightItems = @[
+ [strongSelf getItemForAction:voiceSearchAction
+ title:voiceSearchTitle],
+ [strongSelf getItemForAction:newTabAction title:newTabTitle],
+ [strongSelf getItemForAction:incognitoAction title:incognitoTitle],
+ [strongSelf getItemForAction:qrScannerAction title:qrScannerTitle],
+ nil
sdefresne 2017/02/03 15:47:28 NSArray cannot store "nil" IIRC. Remove.
+ ];
[[CSSearchableIndex defaultSearchableIndex]
indexSearchableItems:spotlightItems

Powered by Google App Engine
This is Rietveld 408576698