OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
174 // Selection persisted across temporary text changes, like popup suggestions. | 174 // Selection persisted across temporary text changes, like popup suggestions. |
175 ui::Range saved_temporary_selection_; | 175 ui::Range saved_temporary_selection_; |
176 | 176 |
177 // Tracking state before and after a possible change. | 177 // Tracking state before and after a possible change. |
178 string16 text_before_change_; | 178 string16 text_before_change_; |
179 ui::Range sel_before_change_; | 179 ui::Range sel_before_change_; |
180 bool ime_composing_before_change_; | 180 bool ime_composing_before_change_; |
181 | 181 |
182 // Was the delete key pressed with an empty selection at the end of the edit? | 182 // Was the delete key pressed with an empty selection at the end of the edit? |
183 bool delete_at_end_pressed_; | 183 bool delete_at_end_pressed_; |
| 184 |
184 LocationBarView* location_bar_view_; | 185 LocationBarView* location_bar_view_; |
185 | 186 |
186 // True if the IME candidate window is open. When this is true, we want to | 187 // True if the IME candidate window is open. When this is true, we want to |
187 // avoid showing the popup. So far, the candidate window is detected only | 188 // avoid showing the popup. So far, the candidate window is detected only |
188 // on Chrome OS. | 189 // on Chrome OS. |
189 bool ime_candidate_window_open_; | 190 bool ime_candidate_window_open_; |
190 | 191 |
191 // Should we select all the text when we see the mouse button get released? | 192 // Should we select all the text when we see the mouse button get released? |
192 // We select in response to a click that focuses the omnibox, but we defer | 193 // We select in response to a click that focuses the omnibox, but we defer |
193 // until release, setting this variable back to false if we saw a drag, to | 194 // until release, setting this variable back to false if we saw a drag, to |
194 // allow the user to select just a portion of the text. | 195 // allow the user to select just a portion of the text. |
195 bool select_all_on_mouse_release_; | 196 bool select_all_on_mouse_release_; |
196 | 197 |
197 // Indicates if we want to select all text in the omnibox when we get a | 198 // Indicates if we want to select all text in the omnibox when we get a |
198 // GESTURE_TAP. We want to select all only when the textfield is not in focus | 199 // GESTURE_TAP. We want to select all only when the textfield is not in focus |
199 // and gets a tap. So we use this variable to remember focus state before tap. | 200 // and gets a tap. So we use this variable to remember focus state before tap. |
200 bool select_all_on_gesture_tap_; | 201 bool select_all_on_gesture_tap_; |
201 | 202 |
202 DISALLOW_COPY_AND_ASSIGN(OmniboxViewViews); | 203 DISALLOW_COPY_AND_ASSIGN(OmniboxViewViews); |
203 }; | 204 }; |
204 | 205 |
205 #endif // CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ | 206 #endif // CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ |
OLD | NEW |