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

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

Issue 12090098: Tapping on omnibox should select all text. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: patch Created 7 years, 11 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 | chrome/browser/ui/views/omnibox/omnibox_view_views.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/omnibox/omnibox_view_views.h
diff --git a/chrome/browser/ui/views/omnibox/omnibox_view_views.h b/chrome/browser/ui/views/omnibox/omnibox_view_views.h
index da660f5311781e90de3c208418a7ead4a7e71cb0..b204d3dd6c96b56eff00d6369a169efb35d5ee69 100644
--- a/chrome/browser/ui/views/omnibox/omnibox_view_views.h
+++ b/chrome/browser/ui/views/omnibox/omnibox_view_views.h
@@ -74,6 +74,9 @@ class OmniboxViewViews
void HandleMouseDragEvent(const ui::MouseEvent& event);
void HandleMouseReleaseEvent(const ui::MouseEvent& event);
+ // Called when a gesture event is generated on textfield.
+ void HandleGestureEvent(const ui::GestureEvent& event);
+
// Called when Focus is set/unset on textfield.
void HandleFocusIn();
void HandleFocusOut();
@@ -219,6 +222,11 @@ class OmniboxViewViews
// allow the user to select just a portion of the text.
bool select_all_on_mouse_release_;
+ // Indicates if we want to select all text in the omnibox when we get a
+ // GESTURE_TAP. We want to select all only when the textfield is not in focus
+ // and gets a tap. So we use this variable to remember focus state before tap.
+ bool select_all_on_gesture_tap_;
+
DISALLOW_COPY_AND_ASSIGN(OmniboxViewViews);
};
« no previous file with comments | « no previous file | chrome/browser/ui/views/omnibox/omnibox_view_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698