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

Unified Diff: chrome/browser/autocomplete/autocomplete_match.h

Issue 18878007: Omnibox: Make the Controller Reorder Matches for Inlining (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Lacks -> has Created 7 years, 4 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/autocomplete_match.h
diff --git a/chrome/browser/autocomplete/autocomplete_match.h b/chrome/browser/autocomplete/autocomplete_match.h
index d5b86247c62e11ab8f23d02dbe3113cb61e4152c..38108dda8e0226647be53b4a0a01f6cfbdb43f8a 100644
--- a/chrome/browser/autocomplete/autocomplete_match.h
+++ b/chrome/browser/autocomplete/autocomplete_match.h
@@ -260,6 +260,17 @@ struct AutocompleteMatch {
// omnibox, if this match becomes the default match. It may be empty.
string16 inline_autocompletion;
+ // If false, the omnibox should prevent this match from being the
+ // default match. Providers should set this to true only if the
+ // user's input, plus any inline autocompletion on this match, would
+ // lead the user to expect a navigation to this match's destination.
+ // For example, with input "foo", a search for "bar" or navigation
+ // to "bar.com" should not set this flag; a navigation to "foo.com"
+ // should only set this flag if ".com" will be inline autocompleted;
+ // and a navigation to "foo/" (an intranet host) or search for "foo"
+ // should set this flag.
+ bool allowed_to_be_default_match;
+
// The URL to actually load when the autocomplete item is selected. This URL
// should be canonical so we can compare URLs with strcmp to avoid dupes.
// It may be empty if there is no possible navigation.

Powered by Google App Engine
This is Rietveld 408576698