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 VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_VIEWS_H_ | 5 #ifndef VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_VIEWS_H_ |
6 #define VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_VIEWS_H_ | 6 #define VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_VIEWS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/string16.h" | 9 #include "base/string16.h" |
10 #include "base/task.h" | 10 #include "base/task.h" |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 virtual void UpdateFont(); | 74 virtual void UpdateFont(); |
75 virtual void UpdateIsPassword(); | 75 virtual void UpdateIsPassword(); |
76 virtual void UpdateEnabled(); | 76 virtual void UpdateEnabled(); |
77 virtual gfx::Insets CalculateInsets(); | 77 virtual gfx::Insets CalculateInsets(); |
78 virtual void UpdateHorizontalMargins(); | 78 virtual void UpdateHorizontalMargins(); |
79 virtual void UpdateVerticalMargins(); | 79 virtual void UpdateVerticalMargins(); |
80 virtual bool SetFocus(); | 80 virtual bool SetFocus(); |
81 virtual View* GetView(); | 81 virtual View* GetView(); |
82 virtual gfx::NativeView GetTestingHandle() const; | 82 virtual gfx::NativeView GetTestingHandle() const; |
83 virtual bool IsIMEComposing() const; | 83 virtual bool IsIMEComposing() const; |
| 84 virtual void GetSelectedRange(TextRange* range) const; |
| 85 virtual void SelectRange(const TextRange& range); |
| 86 virtual size_t GetCursorPosition() const; |
84 virtual bool HandleKeyPressed(const views::KeyEvent& e); | 87 virtual bool HandleKeyPressed(const views::KeyEvent& e); |
85 virtual bool HandleKeyReleased(const views::KeyEvent& e); | 88 virtual bool HandleKeyReleased(const views::KeyEvent& e); |
86 virtual void HandleWillGainFocus(); | 89 virtual void HandleWillGainFocus(); |
87 virtual void HandleDidGainFocus(); | 90 virtual void HandleDidGainFocus(); |
88 virtual void HandleWillLoseFocus(); | 91 virtual void HandleWillLoseFocus(); |
89 | 92 |
90 // ui::SimpleMenuModel::Delegate overrides | 93 // ui::SimpleMenuModel::Delegate overrides |
91 virtual bool IsCommandIdChecked(int command_id) const; | 94 virtual bool IsCommandIdChecked(int command_id) const; |
92 virtual bool IsCommandIdEnabled(int command_id) const; | 95 virtual bool IsCommandIdEnabled(int command_id) const; |
93 virtual bool GetAcceleratorForCommandId(int command_id, | 96 virtual bool GetAcceleratorForCommandId(int command_id, |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
193 // Context menu and its content list for the textfield. | 196 // Context menu and its content list for the textfield. |
194 scoped_ptr<ui::SimpleMenuModel> context_menu_contents_; | 197 scoped_ptr<ui::SimpleMenuModel> context_menu_contents_; |
195 scoped_ptr<Menu2> context_menu_menu_; | 198 scoped_ptr<Menu2> context_menu_menu_; |
196 | 199 |
197 DISALLOW_COPY_AND_ASSIGN(NativeTextfieldViews); | 200 DISALLOW_COPY_AND_ASSIGN(NativeTextfieldViews); |
198 }; | 201 }; |
199 | 202 |
200 } // namespace views | 203 } // namespace views |
201 | 204 |
202 #endif // VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_VIEWS_H_ | 205 #endif // VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_VIEWS_H_ |
OLD | NEW |