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

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

Issue 7056030: Prevent Unnecessary Processing by HQP (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autocomplete/history_quick_provider.cc
===================================================================
--- chrome/browser/autocomplete/history_quick_provider.cc (revision 86194)
+++ chrome/browser/autocomplete/history_quick_provider.cc (working copy)
@@ -46,8 +46,13 @@
bool minimal_changes) {
matches_.clear();
+ // Don't bother with INVALID and FORCED_QUERY. Also pass when looking for
+ // BEST_MATCH and there is no inline autocompletion because none of the HQP
+ // matches can score highly enough to qualify.
if ((input.type() == AutocompleteInput::INVALID) ||
- (input.type() == AutocompleteInput::FORCED_QUERY))
+ (input.type() == AutocompleteInput::FORCED_QUERY) ||
+ (input.matches_requested() == AutocompleteInput::BEST_MATCH &&
+ input.prevent_inline_autocomplete()))
return;
autocomplete_input_ = input;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698