| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 // Update the field with |text| and set the selection. | 149 // Update the field with |text| and set the selection. |
| 150 void SetTextAndSelectedRange(const string16& text, | 150 void SetTextAndSelectedRange(const string16& text, |
| 151 const ui::Range& range); | 151 const ui::Range& range); |
| 152 | 152 |
| 153 // Returns the selected text. | 153 // Returns the selected text. |
| 154 string16 GetSelectedText() const; | 154 string16 GetSelectedText() const; |
| 155 | 155 |
| 156 // Selects the text given by |caret| and |end|. | 156 // Selects the text given by |caret| and |end|. |
| 157 void SelectRange(size_t caret, size_t end); | 157 void SelectRange(size_t caret, size_t end); |
| 158 | 158 |
| 159 AutocompletePopupView* CreatePopupView(Profile* profile, | 159 AutocompletePopupView* CreatePopupView(View* location_bar); |
| 160 View* location_bar); | |
| 161 | 160 |
| 162 views::Textfield* textfield_; | 161 views::Textfield* textfield_; |
| 163 | 162 |
| 164 scoped_ptr<AutocompleteEditModel> model_; | 163 scoped_ptr<AutocompleteEditModel> model_; |
| 165 scoped_ptr<AutocompletePopupView> popup_view_; | 164 scoped_ptr<AutocompletePopupView> popup_view_; |
| 166 AutocompleteEditController* controller_; | 165 AutocompleteEditController* controller_; |
| 167 ToolbarModel* toolbar_model_; | 166 ToolbarModel* toolbar_model_; |
| 168 | 167 |
| 169 // The object that handles additional command functionality exposed on the | 168 // The object that handles additional command functionality exposed on the |
| 170 // edit, such as invoking the keyword editor. | 169 // edit, such as invoking the keyword editor. |
| (...skipping 14 matching lines...) Expand all Loading... |
| 185 ui::Range sel_before_change_; | 184 ui::Range sel_before_change_; |
| 186 bool ime_composing_before_change_; | 185 bool ime_composing_before_change_; |
| 187 | 186 |
| 188 // Was the delete key pressed with an empty selection at the end of the edit? | 187 // Was the delete key pressed with an empty selection at the end of the edit? |
| 189 bool delete_at_end_pressed_; | 188 bool delete_at_end_pressed_; |
| 190 | 189 |
| 191 DISALLOW_COPY_AND_ASSIGN(OmniboxViewViews); | 190 DISALLOW_COPY_AND_ASSIGN(OmniboxViewViews); |
| 192 }; | 191 }; |
| 193 | 192 |
| 194 #endif // CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ | 193 #endif // CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_VIEW_VIEWS_H_ |
| OLD | NEW |