summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autocomplete/autocomplete_edit.cc
diff options
context:
space:
mode:
authorpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-24 20:24:19 +0000
committerpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-24 20:24:19 +0000
commitceb4a1d8df81d1b4c2997e641ef5c3fb55cdd571 (patch)
tree44985f94c6ece6fc4d3fcf9b15827f851ae0957f /chrome/browser/autocomplete/autocomplete_edit.cc
parent4dbac174f218d1b0605fad8f37400becc2f52015 (diff)
downloadchromium_src-ceb4a1d8df81d1b4c2997e641ef5c3fb55cdd571.zip
chromium_src-ceb4a1d8df81d1b4c2997e641ef5c3fb55cdd571.tar.gz
chromium_src-ceb4a1d8df81d1b4c2997e641ef5c3fb55cdd571.tar.bz2
The accidental search infobar was almost never appearing. Fix that regression. Now we don't rely on the presence of a "what you typed" match in the result set; instead the AutocompleteResult determines the alternate nav URL directly.
To do this I refactored some of the code from the history URL provider over to AutocompleteInput. BUG=10808 Review URL: http://codereview.chromium.org/92140 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14463 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autocomplete/autocomplete_edit.cc')
-rw-r--r--chrome/browser/autocomplete/autocomplete_edit.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit.cc b/chrome/browser/autocomplete/autocomplete_edit.cc
index 0065f36..98473ed 100644
--- a/chrome/browser/autocomplete/autocomplete_edit.cc
+++ b/chrome/browser/autocomplete/autocomplete_edit.cc
@@ -204,8 +204,7 @@ bool AutocompleteEditModel::CanPasteAndGo(const std::wstring& text) const {
DCHECK(match != result.end());
paste_and_go_url_ = match->destination_url;
paste_and_go_transition_ = match->transition;
- paste_and_go_alternate_nav_url_ =
- result.GetAlternateNavURL(paste_and_go_controller->input(), match);
+ paste_and_go_alternate_nav_url_ = result.alternate_nav_url();
return paste_and_go_url_.is_valid();
}