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

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

Issue 2846673006: Omnibox: Make InMemoryURLIndex respect hidden URLRows (Closed)
Patch Set: Created 3 years, 8 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/history_quick_provider.cc
diff --git a/components/omnibox/browser/history_quick_provider.cc b/components/omnibox/browser/history_quick_provider.cc
index ea045ad37532f8057b98549775281066ed7d24d5..bccc5508d310e6a1bfddab87719c405f5a4b29bf 100644
--- a/components/omnibox/browser/history_quick_provider.cc
+++ b/components/omnibox/browser/history_quick_provider.cc
@@ -236,8 +236,10 @@ AutocompleteMatch HistoryQuickProvider::QuickMatchToACMatch(
match.inline_autocompletion =
match.fill_into_edit.substr(inline_autocomplete_offset);
}
- match.allowed_to_be_default_match = match.inline_autocompletion.empty() ||
- !PreventInlineAutocomplete(autocomplete_input_);
+ match.allowed_to_be_default_match =
+ match.typed_count > 0 &&
+ (match.inline_autocompletion.empty() ||
+ !PreventInlineAutocomplete(autocomplete_input_));
}
match.EnsureUWYTIsAllowedToBeDefault(autocomplete_input_,
client()->GetTemplateURLService());

Powered by Google App Engine
This is Rietveld 408576698