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

Unified Diff: chrome/browser/ui/views/omnibox/omnibox_view_views.cc

Issue 2435103002: Omnibox: Preserve display text and select all on a focus search (Closed)
Patch Set: Use display_text.length() as caret pos for KEYBOARD_SHORTCUT Created 4 years, 2 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/ui/views/omnibox/omnibox_view_views.cc
diff --git a/chrome/browser/ui/views/omnibox/omnibox_view_views.cc b/chrome/browser/ui/views/omnibox/omnibox_view_views.cc
index 98ad3e568cb4cac06b580895a55fe1527c25a65f..2544f10720e4781da4a660d163d92cee9a1fa22d 100644
--- a/chrome/browser/ui/views/omnibox/omnibox_view_views.cc
+++ b/chrome/browser/ui/views/omnibox/omnibox_view_views.cc
@@ -247,10 +247,8 @@ void OmniboxViewViews::SetUserText(const base::string16& text,
void OmniboxViewViews::EnterKeywordModeForDefaultSearchProvider() {
// Transition the user into keyword mode using their default search provider.
- // Select their query if they typed one.
model()->EnterKeywordModeForDefaultSearchProvider(
KeywordModeEntryMethod::KEYBOARD_SHORTCUT);
- SelectRange(gfx::Range(text().size(), 0));
}
void OmniboxViewViews::GetSelectionBounds(
« no previous file with comments | « chrome/browser/ui/omnibox/omnibox_view_browsertest.cc ('k') | components/omnibox/browser/omnibox_edit_model.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698