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 9c4b4320cf446d7b74d36cce70b5f126f23bc5aa..beb8d17124ff5ac50243bb1c468890a37bd41bf2 100644 |
--- a/chrome/browser/ui/views/omnibox/omnibox_view_views.h |
+++ b/chrome/browser/ui/views/omnibox/omnibox_view_views.h |
@@ -71,8 +71,11 @@ class OmniboxViewViews |
// Called when KeyRelease event is generated on textfield. |
bool HandleKeyReleaseEvent(const views::KeyEvent& event); |
- // Called when the mouse press event is generated on textfield. |
- bool HandleMousePressEvent(const views::MouseEvent& event); |
+ // Called when mouse events are generated on the textfield. |
+ // The views::Textfield implementations will be executed first. |
+ void HandleMousePressEvent(const views::MouseEvent& event); |
+ void HandleMouseDragEvent(const views::MouseEvent& event); |
+ void HandleMouseReleaseEvent(const views::MouseEvent& event); |
// Called when Focus is set/unset on textfield. |
void HandleFocusIn(); |
@@ -215,6 +218,12 @@ class OmniboxViewViews |
// on Chrome OS. |
bool ime_candidate_window_open_; |
+ // Should we select all the text when we see the mouse button get released? |
+ // We select in response to a click that focuses the omnibox, but we defer |
+ // until release, setting this variable back to false if we saw a drag, to |
+ // allow the user to select just a portion of the text. |
+ bool select_all_on_mouse_release_; |
+ |
DISALLOW_COPY_AND_ASSIGN(OmniboxViewViews); |
}; |