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

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

Issue 6628037: views: Moves TextfieldController/TextRange into their own headers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address comments Created 9 years, 9 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 | Annotate | Revision Log
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_
6 #define VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_
7 #pragma once
8
9 #include "base/string16.h"
10
11 namespace views {
12
13 class KeyEvent;
14 class Textfield;
15
16 // This defines the callback interface for other code to be notified of changes
17 // in the state of a text field.
18 class TextfieldController {
19 public:
20 // This method is called whenever the text in the field changes.
21 virtual void ContentsChanged(Textfield* sender,
22 const string16& new_contents) = 0;
23
24 // This method is called to get notified about keystrokes in the edit.
25 // Returns true if the message was handled and should not be processed
26 // further. If it returns false the processing continues.
27 virtual bool HandleKeyEvent(Textfield* sender,
28 const KeyEvent& key_event) = 0;
29 };
30
31 } // namespace views
32
33 #endif // VIEWS_CONTROLS_TEXTFIELD_TEXTFIELD_CONTROLLER_H_
OLDNEW
« no previous file with comments | « views/controls/textfield/textfield.cc ('k') | views/controls/textfield/textfield_views_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698