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

Unified Diff: chrome/browser/autocomplete/history_url_provider.cc

Issue 836213002: Assume all providers may give zero suggest responses. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix compilation issue in athena Created 5 years, 11 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: chrome/browser/autocomplete/history_url_provider.cc
diff --git a/chrome/browser/autocomplete/history_url_provider.cc b/chrome/browser/autocomplete/history_url_provider.cc
index c87a71bd2dd110b763dd113b20488984c263d180..d9084c59544709e579a15dcd2ac419cb65a7bce6 100644
--- a/chrome/browser/autocomplete/history_url_provider.cc
+++ b/chrome/browser/autocomplete/history_url_provider.cc
@@ -481,7 +481,8 @@ HistoryURLProvider::HistoryURLProvider(AutocompleteProviderListener* listener,
}
void HistoryURLProvider::Start(const AutocompleteInput& input,
- bool minimal_changes) {
+ bool minimal_changes,
+ bool called_due_to_focus) {
// NOTE: We could try hard to do less work in the |minimal_changes| case
// here; some clever caching would let us reuse the raw matches from the
// history DB without re-querying. However, we'd still have to go back to
@@ -496,7 +497,8 @@ void HistoryURLProvider::Start(const AutocompleteInput& input,
matches_.clear();
- if ((input.type() == metrics::OmniboxInputType::INVALID) ||
+ if (called_due_to_focus ||
+ (input.type() == metrics::OmniboxInputType::INVALID) ||
(input.type() == metrics::OmniboxInputType::FORCED_QUERY))
return;
« no previous file with comments | « chrome/browser/autocomplete/history_url_provider.h ('k') | chrome/browser/autocomplete/history_url_provider_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698