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

Side by Side Diff: third_party/WebKit/Source/core/dom/Text.h

Issue 2421793002: Move layout tree reconstruction code for Text nodes into new function (Closed)
Patch Set: Edits post Elliott's lgtm Created 4 years, 1 month 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/Text.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights 4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights
5 * reserved. 5 * reserved.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 // then returns a node not merged. 47 // then returns a node not merged.
48 Node* mergeNextSiblingNodesIfPossible(); 48 Node* mergeNextSiblingNodesIfPossible();
49 Text* splitText(unsigned offset, ExceptionState&); 49 Text* splitText(unsigned offset, ExceptionState&);
50 50
51 // DOM Level 3: http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-1312295772 51 // DOM Level 3: http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-1312295772
52 52
53 String wholeText() const; 53 String wholeText() const;
54 Text* replaceWholeText(const String&); 54 Text* replaceWholeText(const String&);
55 55
56 void recalcTextStyle(StyleRecalcChange, Text* nextTextSibling); 56 void recalcTextStyle(StyleRecalcChange, Text* nextTextSibling);
57 void rebuildTextLayoutTree(Text* nextTextSibling);
57 bool textLayoutObjectIsNeeded(const ComputedStyle&, 58 bool textLayoutObjectIsNeeded(const ComputedStyle&,
58 const LayoutObject& parent) const; 59 const LayoutObject& parent) const;
59 LayoutText* createTextLayoutObject(const ComputedStyle&); 60 LayoutText* createTextLayoutObject(const ComputedStyle&);
60 void updateTextLayoutObject(unsigned offsetOfReplacedData, 61 void updateTextLayoutObject(unsigned offsetOfReplacedData,
61 unsigned lengthOfReplacedData); 62 unsigned lengthOfReplacedData);
62 63
63 void attachLayoutTree(const AttachContext& = AttachContext()) final; 64 void attachLayoutTree(const AttachContext& = AttachContext()) final;
64 void reattachLayoutTreeIfNeeded(const AttachContext& = AttachContext()); 65 void reattachLayoutTreeIfNeeded(const AttachContext& = AttachContext());
65 66
66 bool canContainRangeEndPoint() const final { return true; } 67 bool canContainRangeEndPoint() const final { return true; }
(...skipping 15 matching lines...) Expand all
82 bool needsWhitespaceLayoutObject(); 83 bool needsWhitespaceLayoutObject();
83 84
84 virtual Text* cloneWithData(const String&); 85 virtual Text* cloneWithData(const String&);
85 }; 86 };
86 87
87 DEFINE_NODE_TYPE_CASTS(Text, isTextNode()); 88 DEFINE_NODE_TYPE_CASTS(Text, isTextNode());
88 89
89 } // namespace blink 90 } // namespace blink
90 91
91 #endif // Text_h 92 #endif // Text_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/Text.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698