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

Unified Diff: chrome/browser/ui/startup/startup_browser_creator.cc

Issue 1477783004: Add a preference to control Windows desktop search redirection. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Declare feature in header file. Created 5 years, 1 month 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: chrome/browser/ui/startup/startup_browser_creator.cc
diff --git a/chrome/browser/ui/startup/startup_browser_creator.cc b/chrome/browser/ui/startup/startup_browser_creator.cc
index 9e9daf6ae563672ae4a6726e344f9513d7fda910..f5888b3fb23c69a4e289b166f111c1e2c94c3b94 100644
--- a/chrome/browser/ui/startup/startup_browser_creator.cc
+++ b/chrome/browser/ui/startup/startup_browser_creator.cc
@@ -92,8 +92,7 @@
#if defined(OS_WIN)
#include "chrome/browser/metrics/jumplist_metrics_win.h"
-#include "components/search_engines/detect_desktop_search_win.h"
-#include "components/search_engines/search_engines_switches.h"
+#include "components/search_engines/desktop_search_win.h"
#endif
#if defined(ENABLE_PRINT_PREVIEW)
@@ -553,8 +552,9 @@ std::vector<GURL> StartupBrowserCreator::GetURLsFromCommandLine(
GURL url = GURL(param.MaybeAsASCII());
#if defined(OS_WIN)
- if (command_line.HasSwitch(
- switches::kUseDefaultSearchProviderForDesktopSearch)) {
+ if (WindowsDesktopSearchRedirectionFeatureIsEnabled() &&
+ GetWindowsDesktopSearchRedirectionPref(profile->GetPrefs()) ==
+ WindowsDesktopSearchRedirectionPref::ENABLED) {
TemplateURLService* template_url_service =
TemplateURLServiceFactory::GetForProfile(profile);
DCHECK(template_url_service);

Powered by Google App Engine
This is Rietveld 408576698