Index: ui/views/controls/textfield/textfield.cc |
diff --git a/ui/views/controls/textfield/textfield.cc b/ui/views/controls/textfield/textfield.cc |
index e05f969de2962679be6f5880e512c7cd7a1970bb..77cbdfae58dd6fe007f1234976a658dd5d953c94 100644 |
--- a/ui/views/controls/textfield/textfield.cc |
+++ b/ui/views/controls/textfield/textfield.cc |
@@ -1753,6 +1753,9 @@ void Textfield::RevealPasswordChar(int index) { |
} |
void Textfield::CreateTouchSelectionControllerAndNotifyIt() { |
+ if (!HasFocus()) |
+ return; |
+ |
if (!touch_selection_controller_) { |
touch_selection_controller_.reset( |
ui::TouchSelectionController::create(this)); |