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

Unified Diff: components/omnibox/browser/autocomplete_result.cc

Issue 1855423003: Interpret '?' and Ctrl-K or Ctrl-E as putting omnibox in keyword search mode for Default Search Pro… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add includes for mac tests Created 4 years, 6 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: components/omnibox/browser/autocomplete_result.cc
diff --git a/components/omnibox/browser/autocomplete_result.cc b/components/omnibox/browser/autocomplete_result.cc
index 0cf577cd68ed823e0c555409dcf9434c5a5c20a2..1a126d34688986348821355e2ed685f2fb5c88d8 100644
--- a/components/omnibox/browser/autocomplete_result.cc
+++ b/components/omnibox/browser/autocomplete_result.cc
@@ -171,13 +171,10 @@ void AutocompleteResult::SortAndCull(
// sure the type of destination is what the user would expect given the
// input.
if (default_match_->destination_url.is_valid()) {
- // We shouldn't get query matches for URL inputs, or non-query matches
- // for query inputs.
if (AutocompleteMatch::IsSearchType(default_match_->type)) {
+ // We shouldn't get query matches for URL inputs.
DCHECK_NE(metrics::OmniboxInputType::URL, input.type()) << debug_info;
} else {
- DCHECK_NE(metrics::OmniboxInputType::FORCED_QUERY, input.type())
- << debug_info;
// If the user explicitly typed a scheme, the default match should
// have the same scheme.
if ((input.type() == metrics::OmniboxInputType::URL) &&
« no previous file with comments | « components/omnibox/browser/autocomplete_provider.h ('k') | components/omnibox/browser/base_search_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698