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

Unified Diff: chrome/browser/ui/omnibox/omnibox_edit_model.cc

Issue 1129733006: Omnibox - Code Cleanup - Remove Unnecessary is_history_what_you_typed_match (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 | « chrome/browser/resources/omnibox/omnibox.js ('k') | chrome/browser/ui/omnibox/omnibox_popup_model.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/omnibox/omnibox_edit_model.cc
diff --git a/chrome/browser/ui/omnibox/omnibox_edit_model.cc b/chrome/browser/ui/omnibox/omnibox_edit_model.cc
index b770759f157267b61aabbfb720144bd2bb70d90b..88a54fc7296f6bd280a6dfba10519c04c6535299 100644
--- a/chrome/browser/ui/omnibox/omnibox_edit_model.cc
+++ b/chrome/browser/ui/omnibox/omnibox_edit_model.cc
@@ -54,6 +54,7 @@
#include "components/bookmarks/browser/bookmark_model.h"
#include "components/favicon/content/content_favicon_driver.h"
#include "components/metrics/proto/omnibox_event.pb.h"
+#include "components/omnibox/autocomplete_match_type.h"
#include "components/omnibox/autocomplete_provider.h"
#include "components/omnibox/keyword_provider.h"
#include "components/omnibox/search_provider.h"
@@ -697,8 +698,9 @@ void OmniboxEditModel::AcceptInput(WindowOpenDisposition disposition,
// (e.g. manually retyping the same search query), and it seems wrong to
// treat this as a reload.
match.transition = ui::PAGE_TRANSITION_RELOAD;
- } else if (for_drop || ((paste_state_ != NONE) &&
- match.is_history_what_you_typed_match)) {
+ } else if (for_drop ||
+ ((paste_state_ != NONE) &&
+ (match.type == AutocompleteMatchType::URL_WHAT_YOU_TYPED))) {
// When the user pasted in a URL and hit enter, score it like a link click
// rather than a normal typed URL, so it doesn't get inline autocompleted
// as aggressively later.
« no previous file with comments | « chrome/browser/resources/omnibox/omnibox.js ('k') | chrome/browser/ui/omnibox/omnibox_popup_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698