diff --git a/ios/chrome/app/spotlight/BUILD.gn b/ios/chrome/app/spotlight/BUILD.gn index bd7c9cf8638d2..dde51d7ea46ba 100644 --- a/ios/chrome/app/spotlight/BUILD.gn +++ b/ios/chrome/app/spotlight/BUILD.gn @@ -34,7 +34,6 @@ source_set("spotlight") { "//ios/chrome/browser/suggestions", "//ios/chrome/browser/sync", "//ios/chrome/browser/ui/ntp:ntp_internal", - "//ios/chrome/common", "//ios/chrome/common/app_group", "//ios/public/provider/chrome/browser", "//ios/public/provider/chrome/browser/spotlight", diff --git a/ios/chrome/app/spotlight/base_spotlight_manager.mm b/ios/chrome/app/spotlight/base_spotlight_manager.mm index 4e912fb6f6a79..c30fb6f13f0e4 100644 --- a/ios/chrome/app/spotlight/base_spotlight_manager.mm +++ b/ios/chrome/app/spotlight/base_spotlight_manager.mm @@ -8,14 +8,12 @@ #import #include "base/mac/bind_objc_block.h" -#include "base/mac/foundation_util.h" #include "base/strings/sys_string_conversions.h" #include "base/task/cancelable_task_tracker.h" #include "components/favicon/core/fallback_url_util.h" #include "components/favicon/core/large_icon_service.h" #include "components/favicon_base/fallback_icon_style.h" #include "components/favicon_base/favicon_types.h" -#include "ios/chrome/common/x_callback_url.h" #include "ios/chrome/grit/ios_strings.h" #include "ios/public/provider/chrome/browser/chrome_browser_provider.h" #include "ios/public/provider/chrome/browser/spotlight/spotlight_provider.h" @@ -150,20 +148,7 @@ - (NSArray*)spotlightItemsWithURL:(const GURL&)indexedURL favicon:(UIImage*)favicon defaultTitle:(NSString*)defaultTitle { DCHECK(defaultTitle); - - GURL urlToOpen = indexedURL; - NSString* scheme = base::mac::ObjCCast([[NSBundle mainBundle] - objectForInfoDictionaryKey:@"KSChannelChromeScheme"]); - - if (scheme) { - std::map parameters; - parameters["url"] = urlToOpen.spec(); - urlToOpen = CreateXCallbackURLWithParameters( - base::SysNSStringToUTF8(scheme), "open", GURL::EmptyGURL(), - GURL::EmptyGURL(), GURL::EmptyGURL(), parameters); - } - - NSURL* nsURL = net::NSURLWithGURL(urlToOpen); + NSURL* nsURL = net::NSURLWithGURL(indexedURL); std::string description = indexedURL.SchemeIsCryptographic() ? indexedURL.GetOrigin().spec() : indexedURL.spec();