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 UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_H_ | 5 #ifndef UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_H_ |
6 #define UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_H_ | 6 #define UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
275 virtual bool GetTextFromRange(const gfx::Range& range, | 275 virtual bool GetTextFromRange(const gfx::Range& range, |
276 base::string16* text) const OVERRIDE; | 276 base::string16* text) const OVERRIDE; |
277 virtual void OnInputMethodChanged() OVERRIDE; | 277 virtual void OnInputMethodChanged() OVERRIDE; |
278 virtual bool ChangeTextDirectionAndLayoutAlignment( | 278 virtual bool ChangeTextDirectionAndLayoutAlignment( |
279 base::i18n::TextDirection direction) OVERRIDE; | 279 base::i18n::TextDirection direction) OVERRIDE; |
280 virtual void ExtendSelectionAndDelete(size_t before, size_t after) OVERRIDE; | 280 virtual void ExtendSelectionAndDelete(size_t before, size_t after) OVERRIDE; |
281 virtual void EnsureCaretInRect(const gfx::Rect& rect) OVERRIDE; | 281 virtual void EnsureCaretInRect(const gfx::Rect& rect) OVERRIDE; |
282 virtual void OnCandidateWindowShown() OVERRIDE; | 282 virtual void OnCandidateWindowShown() OVERRIDE; |
283 virtual void OnCandidateWindowUpdated() OVERRIDE; | 283 virtual void OnCandidateWindowUpdated() OVERRIDE; |
284 virtual void OnCandidateWindowHidden() OVERRIDE; | 284 virtual void OnCandidateWindowHidden() OVERRIDE; |
| 285 virtual bool IsEditingCommandEnabled(int command_id) OVERRIDE; |
| 286 virtual void ExecuteEditingCommand(int command_id) OVERRIDE; |
285 | 287 |
286 protected: | 288 protected: |
287 // Returns the TextfieldModel's text/cursor/selection rendering model. | 289 // Returns the TextfieldModel's text/cursor/selection rendering model. |
288 gfx::RenderText* GetRenderText() const; | 290 gfx::RenderText* GetRenderText() const; |
289 | 291 |
290 gfx::Point last_click_location() const { return last_click_location_; } | 292 gfx::Point last_click_location() const { return last_click_location_; } |
291 | 293 |
292 // Get the text from the selection clipboard. | 294 // Get the text from the selection clipboard. |
293 virtual base::string16 GetSelectionClipboardText() const; | 295 virtual base::string16 GetSelectionClipboardText() const; |
294 | 296 |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
434 | 436 |
435 // Used to bind callback functions to this object. | 437 // Used to bind callback functions to this object. |
436 base::WeakPtrFactory<Textfield> weak_ptr_factory_; | 438 base::WeakPtrFactory<Textfield> weak_ptr_factory_; |
437 | 439 |
438 DISALLOW_COPY_AND_ASSIGN(Textfield); | 440 DISALLOW_COPY_AND_ASSIGN(Textfield); |
439 }; | 441 }; |
440 | 442 |
441 } // namespace views | 443 } // namespace views |
442 | 444 |
443 #endif // UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_H_ | 445 #endif // UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_H_ |
OLD | NEW |