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

Side by Side Diff: Source/core/editing/FrameSelectionTest.cpp

Issue 421883002: Oilpan: fix build after r179003. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/editing/FrameSelection.h" 6 #include "core/editing/FrameSelection.h"
7 7
8 #include "bindings/core/v8/ExceptionStatePlaceholder.h" 8 #include "bindings/core/v8/ExceptionStatePlaceholder.h"
9 #include "core/dom/Document.h" 9 #include "core/dom/Document.h"
10 #include "core/dom/Element.h" 10 #include "core/dom/Element.h"
(...skipping 26 matching lines...) Expand all
37 RawPtr<HTMLDocument> m_document; 37 RawPtr<HTMLDocument> m_document;
38 RefPtrWillBePersistent<Text> m_textNode; 38 RefPtrWillBePersistent<Text> m_textNode;
39 }; 39 };
40 40
41 void FrameSelectionTest::SetUp() 41 void FrameSelectionTest::SetUp()
42 { 42 {
43 m_dummyPageHolder = DummyPageHolder::create(IntSize(800, 600)); 43 m_dummyPageHolder = DummyPageHolder::create(IntSize(800, 600));
44 m_document = toHTMLDocument(&m_dummyPageHolder->document()); 44 m_document = toHTMLDocument(&m_dummyPageHolder->document());
45 ASSERT(m_document); 45 ASSERT(m_document);
46 m_textNode = m_document->createTextNode("Hello, World!"); 46 m_textNode = m_document->createTextNode("Hello, World!");
47 m_document->body()->appendChild(m_textNode); 47 m_document->body()->appendChild(m_textNode.get());
48 } 48 }
49 49
50 HTMLDocument& FrameSelectionTest::document() const 50 HTMLDocument& FrameSelectionTest::document() const
51 { 51 {
52 return *m_document; 52 return *m_document;
53 } 53 }
54 54
55 void FrameSelectionTest::setSelection(const VisibleSelection& newSelection) 55 void FrameSelectionTest::setSelection(const VisibleSelection& newSelection)
56 { 56 {
57 m_dummyPageHolder->frame().selection().setSelection(newSelection); 57 m_dummyPageHolder->frame().selection().setSelection(newSelection);
(...skipping 25 matching lines...) Expand all
83 // Create a new VisibleSelection for the new document without frame and 83 // Create a new VisibleSelection for the new document without frame and
84 // update FrameSelection with the selection. 84 // update FrameSelection with the selection.
85 VisibleSelection invalidSelection; 85 VisibleSelection invalidSelection;
86 invalidSelection.setWithoutValidation(Position(anotherText, 0), Position(ano therText, 5)); 86 invalidSelection.setWithoutValidation(Position(anotherText, 0), Position(ano therText, 5));
87 setSelection(invalidSelection); 87 setSelection(invalidSelection);
88 88
89 EXPECT_TRUE(selection().isNone()); 89 EXPECT_TRUE(selection().isNone());
90 } 90 }
91 91
92 } 92 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698