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

Unified Diff: ui/views/controls/textfield/textfield_unittest.cc

Issue 302363002: Revert "Fix textfield blur, to prevent resetting the text input client when navigating between text… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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
« no previous file with comments | « ui/views/controls/textfield/textfield.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/textfield/textfield_unittest.cc
diff --git a/ui/views/controls/textfield/textfield_unittest.cc b/ui/views/controls/textfield/textfield_unittest.cc
index cf5959d5d97e45c26f92206c4238f25ba6ccbe0a..f52caf007d1a03721b42683d86e094c6d293fb7d 100644
--- a/ui/views/controls/textfield/textfield_unittest.cc
+++ b/ui/views/controls/textfield/textfield_unittest.cc
@@ -665,35 +665,6 @@ TEST_F(TextfieldTest, FocusTraversalTest) {
EXPECT_EQ(1, GetFocusedView()->id());
}
-// Verify that the text input client properly tracks changing focus between text
-// fields. See crbug/365741.
-TEST_F(TextfieldTest, TextInputClientFollowsFocusChange) {
- InitTextfields(2);
- textfield_->RequestFocus();
-
- EXPECT_EQ(textfield_, input_method_->GetTextInputClient());
-
- widget_->GetFocusManager()->AdvanceFocus(false);
- Textfield* second = static_cast<Textfield*>(GetFocusedView());
- EXPECT_EQ(2, second->id());
- EXPECT_EQ(second, input_method_->GetTextInputClient());
-
- ui::MouseEvent click(ui::ET_MOUSE_PRESSED, gfx::Point(), gfx::Point(),
- ui::EF_LEFT_MOUSE_BUTTON, ui::EF_LEFT_MOUSE_BUTTON);
- textfield_->OnMousePressed(click);
- EXPECT_EQ(textfield_, input_method_->GetTextInputClient());
-
- input_method_->Clear();
-
- // Verify that blur does not reset text input client if field does not
- // have focus.
- second->OnBlur();
- EXPECT_FALSE(input_method_->text_input_type_changed());
- // Verify that blur on the focused text field resets the text input client.
- textfield_->OnBlur();
- EXPECT_TRUE(input_method_->text_input_type_changed());
-}
-
TEST_F(TextfieldTest, ContextMenuDisplayTest) {
InitTextfield();
EXPECT_TRUE(textfield_->context_menu_controller());
« no previous file with comments | « ui/views/controls/textfield/textfield.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698