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

Unified Diff: views/controls/textfield/native_textfield_views.h

Issue 6685082: Refactor Textfield and AutocompleteEditViewViews. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address review feedbacks. 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 side-by-side diff with in-line comments
Download patch
Index: views/controls/textfield/native_textfield_views.h
diff --git a/views/controls/textfield/native_textfield_views.h b/views/controls/textfield/native_textfield_views.h
index 1f801470b7a39c4473098cc344ae279fd5576539..7cc8317faa26978d747ac1d264ad5d950b6f9bcd 100644
--- a/views/controls/textfield/native_textfield_views.h
+++ b/views/controls/textfield/native_textfield_views.h
@@ -169,10 +169,6 @@ class NativeTextfieldViews : public views::View,
// Handle the keyevent.
bool HandleKeyEvent(const KeyEvent& key_event);
- // Utility function. Gets the character corresponding to a keyevent.
- // Returns 0 if the character is not printable.
- char16 GetPrintableChar(const KeyEvent& key_event);
-
// Find a cusor position for given |point| in this views coordinates.
size_t FindCursorPosition(const gfx::Point& point) const;
@@ -194,6 +190,16 @@ class NativeTextfieldViews : public views::View,
// Utility function to create the context menu if one does not already exist.
void InitContextMenuIfRequired();
+ // Convenience method to call TextfieldController::OnBeforeUserAction();
+ void OnBeforeUserAction();
+
+ // Convenience method to call TextfieldController::OnAfterUserAction();
+ void OnAfterUserAction();
+
+ // Checks if a char is ok to be inserted into the textfield. The |ch| is a
+ // modified character, i.e., modifiers took effect when generating this char.
+ static bool ShouldInsertChar(char16 ch, int flags);
+
// The parent textfield, the owner of this object.
Textfield* textfield_;
« no previous file with comments | « chrome/browser/autocomplete/autocomplete_edit_view_views.cc ('k') | views/controls/textfield/native_textfield_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698