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

Side by Side Diff: Source/core/html/HTMLTextFormControlElementTest.cpp

Issue 340273003: Rename innerTextElement/Value used in <input> and <textarea> to innerEditor. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "config.h" 5 #include "config.h"
6 #include "core/html/HTMLTextFormControlElement.h" 6 #include "core/html/HTMLTextFormControlElement.h"
7 7
8 #include "core/frame/FrameView.h" 8 #include "core/frame/FrameView.h"
9 #include "core/html/HTMLDocument.h" 9 #include "core/html/HTMLDocument.h"
10 #include "core/testing/DummyPageHolder.h" 10 #include "core/testing/DummyPageHolder.h"
(...skipping 24 matching lines...) Expand all
35 document.view()->updateLayoutAndStyleIfNeededRecursive(); 35 document.view()->updateLayoutAndStyleIfNeededRecursive();
36 m_textControl = toHTMLTextFormControlElement(document.getElementById("textar ea")); 36 m_textControl = toHTMLTextFormControlElement(document.getElementById("textar ea"));
37 m_textControl->focus(); 37 m_textControl->focus();
38 } 38 }
39 39
40 TEST_F(HTMLTextFormControlElementTest, SetSelectionRange) 40 TEST_F(HTMLTextFormControlElementTest, SetSelectionRange)
41 { 41 {
42 EXPECT_EQ(0, textControl().selectionStart()); 42 EXPECT_EQ(0, textControl().selectionStart());
43 EXPECT_EQ(0, textControl().selectionEnd()); 43 EXPECT_EQ(0, textControl().selectionEnd());
44 44
45 textControl().setInnerTextValue("Hello, text form."); 45 textControl().setInnerEditorValue("Hello, text form.");
46 EXPECT_EQ(0, textControl().selectionStart()); 46 EXPECT_EQ(0, textControl().selectionStart());
47 EXPECT_EQ(0, textControl().selectionEnd()); 47 EXPECT_EQ(0, textControl().selectionEnd());
48 48
49 textControl().setSelectionRange(1, 3); 49 textControl().setSelectionRange(1, 3);
50 EXPECT_EQ(1, textControl().selectionStart()); 50 EXPECT_EQ(1, textControl().selectionStart());
51 EXPECT_EQ(3, textControl().selectionEnd()); 51 EXPECT_EQ(3, textControl().selectionEnd());
52 } 52 }
53 53
54 } 54 }
OLDNEW
« no previous file with comments | « Source/core/html/HTMLTextFormControlElement.cpp ('k') | Source/core/html/forms/NumberInputType.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698