Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: ui/views/controls/textfield/textfield_controller.h

Issue 2952763002: SearchBoxView now enables/disables cursor based on user interaction. (Closed)
Patch Set: SearchBoxView now enables/disables cursor based on user interaction. Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_CONTROLLER_H_ 5 #ifndef UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_
6 #define UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_ 6 #define UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_
7 7
8 #include <set> 8 #include <set>
9 9
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 25 matching lines...) Expand all
36 // further. If it returns false the processing continues. 36 // further. If it returns false the processing continues.
37 virtual bool HandleKeyEvent(Textfield* sender, 37 virtual bool HandleKeyEvent(Textfield* sender,
38 const ui::KeyEvent& key_event); 38 const ui::KeyEvent& key_event);
39 39
40 // This method is called to get notified about mouse events in the edit. 40 // This method is called to get notified about mouse events in the edit.
41 // Returns true if the message was handled and should not be processed 41 // Returns true if the message was handled and should not be processed
42 // further. Currently, only mouse down events are sent here. 42 // further. Currently, only mouse down events are sent here.
43 virtual bool HandleMouseEvent(Textfield* sender, 43 virtual bool HandleMouseEvent(Textfield* sender,
44 const ui::MouseEvent& mouse_event); 44 const ui::MouseEvent& mouse_event);
45 45
46 // This method is called to notify that a gesture event has occured in the
vadimt 2017/06/22 00:53:06 Skip "This method is"
newcomer 2017/06/22 16:17:22 Done and fixed above comments to match.
47 // textfield. Currently, only tap events are sent here.
vadimt 2017/06/22 00:53:05 OnGesture
newcomer 2017/06/22 16:17:22 Done.
48 virtual void NotifyOfGestureEvent();
49
46 // Called before performing a user action that may change the textfield. 50 // Called before performing a user action that may change the textfield.
47 // It's currently only supported by Views implementation. 51 // It's currently only supported by Views implementation.
48 virtual void OnBeforeUserAction(Textfield* sender) {} 52 virtual void OnBeforeUserAction(Textfield* sender) {}
49 53
50 // Called after performing a user action that may change the textfield. 54 // Called after performing a user action that may change the textfield.
51 // It's currently only supported by Views implementation. 55 // It's currently only supported by Views implementation.
52 virtual void OnAfterUserAction(Textfield* sender) {} 56 virtual void OnAfterUserAction(Textfield* sender) {}
53 57
54 // Called after performing a Cut or Copy operation. 58 // Called after performing a Cut or Copy operation.
55 virtual void OnAfterCutOrCopy(ui::ClipboardType clipboard_type) {} 59 virtual void OnAfterCutOrCopy(ui::ClipboardType clipboard_type) {}
(...skipping 23 matching lines...) Expand all
79 // Gives the controller a chance to modify the context menu contents. 83 // Gives the controller a chance to modify the context menu contents.
80 virtual void UpdateContextMenu(ui::SimpleMenuModel* menu_contents) {} 84 virtual void UpdateContextMenu(ui::SimpleMenuModel* menu_contents) {}
81 85
82 protected: 86 protected:
83 virtual ~TextfieldController() {} 87 virtual ~TextfieldController() {}
84 }; 88 };
85 89
86 } // namespace views 90 } // namespace views
87 91
88 #endif // UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_ 92 #endif // UI_VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698