Changeset 201534 in webkit
- Timestamp:
- May 31, 2016, 3:51:01 PM (10 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 10 edited
-
ChangeLog (modified) (1 diff)
-
WebCore.xcodeproj/project.pbxproj (modified) (1 diff)
-
dom/Document.cpp (modified) (3 diffs)
-
dom/Document.h (modified) (3 diffs)
-
rendering/RenderBlockFlow.cpp (modified) (1 diff)
-
rendering/RenderElement.cpp (modified) (2 diffs)
-
rendering/TextAutoSizing.cpp (modified) (6 diffs)
-
rendering/TextAutoSizing.h (modified) (5 diffs)
-
rendering/style/RenderStyle.cpp (modified) (1 diff)
-
rendering/style/RenderStyle.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r201529 r201534 1 2016-05-31 Chris Dumez <cdumez@apple.com> 2 3 Clean up / modernize iOS text autosizing code 4 https://bugs.webkit.org/show_bug.cgi?id=158217 5 6 Reviewed by Darin Adler. 7 8 Clean up / modernize iOS text autosizing code. 9 10 I think iOS text autosizing code is too intrusive inside the RenderStyle 11 class but I have not updated this part of the code yet to limit patch 12 size. This patch focuses on the TextAutoSizing.* and text autosizing 13 code in the Document class. 14 15 * WebCore.xcodeproj/project.pbxproj: 16 * dom/Document.cpp: 17 (WebCore::TextAutoSizingTraits::constructDeletedValue): Deleted. 18 (WebCore::TextAutoSizingTraits::isDeletedValue): Deleted. 19 Move TextAutoSizingTraits to the TextAutoSizing header to 20 promote reuse and make the text autosizing code a little less 21 intrusive. 22 23 (WebCore::Document::addAutoSizingNode): 24 - Drop local 'key' variable as it is only used once. 25 - Use std::make_unique<> to construct the TextAutoSizingValue 26 as it is no longer ref-counted. 27 28 (WebCore::Document::validateAutoSizingNodes): 29 Iterate over the textAutosizedNodes HashMap only once instead 30 of twice. TextAutoSizingValue::adjustTextNodeSizes() was updated 31 to return an enum class so we know from that value if we can 32 remove the value from the HashSet or not, without having to rely 33 on TextAutoSizingValue::numNodes(), which I removed in this 34 patch. 35 36 (WebCore::Document::clearAutoSizingNodes): 37 Updated the TextAutoSizingValue destructor to call reset() so 38 we don't have to explicitly call reset() on each value before 39 clearing the textAutosizedNodes HashMap. 40 41 * dom/Document.h: 42 - Move TextAutoSizingTraits to the TextAutosizing header. 43 - Rename resetAutosizingNodes() to clearAutoSizingNodes() as 44 the method now only clears the textAutosizedNodes HashMap 45 and reset() is now an implementation detail for 46 TextAutoSizingValue. 47 48 * rendering/RenderElement.cpp: 49 (WebCore::RenderElement::resetTextAutosizing): 50 Call clearAutoSizingNodes() as it was renamed. 51 52 * rendering/TextAutoSizing.cpp: 53 (WebCore::TextAutoSizingKey::TextAutoSizingKey): 54 - Use value of -1 for std::unique_ptr m_style member for distinguishing 55 a HashTable deleted value, instead of having an extra m_isDeleted 56 data member for this purpose. 57 - Take RenderStyle parameter by reference and drop the null check as the 58 call site can never pass nullptr. 59 60 (WebCore::TextAutoSizingValue::addTextNode): 61 - Rename addNode() to addTextNode() for clarity. 62 63 (WebCore::TextAutoSizingValue::~TextAutoSizingValue): 64 Update destructor to call reset() so that the Document does not have to 65 call it explicitly and can instead just clear the HashMap, which will 66 destroy the TextAutoSizingValue objects. 67 68 (WebCore::TextAutoSizingValue::reset): 69 Rename text to renderer for clarity. 70 71 * rendering/TextAutoSizing.h: 72 - Make TextAutoSizingValue as fast allocated. 73 - Update TextAutoSizingValue to no longer be refcounted as ownership is never 74 shared. The Document owns those. 75 - Drop the factory function for TextAutoSizingValue and make the constructor 76 public now that the class is no longer refcounted. 77 - Make reset() method private now that it is called from the destructor and 78 the Document is no longer expected to explicitly call it. 79 - Update adjustTextNodeSizes() to return a StillHasNodes enum class and the 80 Document can rely on the determine if it can drop the TextAutoSizingValue 81 from its HashMap (and therefore destroy the object). 82 - Drop numNodes() method as it is no longer needed. 83 84 1 85 2016-05-31 Dave Hyatt <hyatt@apple.com> 2 86 -
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
r201504 r201534 475 475 0F54DCE21880F901003EEDBB /* DOMGestureEventInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F54DCDF1880F901003EEDBB /* DOMGestureEventInternal.h */; }; 476 476 0F54DCE51881051D003EEDBB /* TextAutoSizing.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0F54DCE31881051D003EEDBB /* TextAutoSizing.cpp */; }; 477 0F54DCE61881051D003EEDBB /* TextAutoSizing.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F54DCE41881051D003EEDBB /* TextAutoSizing.h */; };477 0F54DCE61881051D003EEDBB /* TextAutoSizing.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F54DCE41881051D003EEDBB /* TextAutoSizing.h */; settings = {ATTRIBUTES = (Private, ); }; }; 478 478 0F54DD081881D5F5003EEDBB /* Touch.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F54DD051881D5F5003EEDBB /* Touch.h */; }; 479 479 0F54DD091881D5F5003EEDBB /* TouchEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F54DD061881D5F5003EEDBB /* TouchEvent.h */; }; -
trunk/Source/WebCore/dom/Document.cpp
r201496 r201534 224 224 #endif 225 225 226 #if ENABLE(IOS_TEXT_AUTOSIZING)227 #include "TextAutoSizing.h"228 #endif229 230 226 #if ENABLE(MATHML) 231 227 #include "MathMLElement.h" … … 425 421 426 422 uint64_t Document::s_globalTreeVersion = 0; 427 428 #if ENABLE(IOS_TEXT_AUTOSIZING)429 void TextAutoSizingTraits::constructDeletedValue(TextAutoSizingKey& slot)430 {431 new (&slot) TextAutoSizingKey(TextAutoSizingKey::Deleted);432 }433 434 bool TextAutoSizingTraits::isDeletedValue(const TextAutoSizingKey& value)435 {436 return value.isDeleted();437 }438 #endif439 423 440 424 HashSet<Document*>& Document::allDocuments() … … 5299 5283 #if ENABLE(IOS_TEXT_AUTOSIZING) 5300 5284 5301 void Document::addAutoSizingNode(Text& node, float candidateSize) 5302 { 5303 LOG(TextAutosizing, " addAutoSizingNode %p candidateSize=%f", &node, candidateSize); 5304 5305 TextAutoSizingKey key(&node.renderer()->style()); 5306 auto addResult = m_textAutoSizedNodes.ensure(WTFMove(key), [] { 5307 return TextAutoSizingValue::create(); 5285 void Document::addAutoSizedNode(Text& node, float candidateSize) 5286 { 5287 LOG(TextAutosizing, " addAutoSizedNode %p candidateSize=%f", &node, candidateSize); 5288 auto addResult = m_textAutoSizedNodes.add<TextAutoSizingHashTranslator>(node.renderer()->style(), nullptr); 5289 if (addResult.isNewEntry) 5290 addResult.iterator->value = std::make_unique<TextAutoSizingValue>(); 5291 addResult.iterator->value->addTextNode(node, candidateSize); 5292 } 5293 5294 void Document::updateAutoSizedNodes() 5295 { 5296 m_textAutoSizedNodes.removeIf([](auto& keyAndValue) { 5297 return keyAndValue.value->adjustTextNodeSizes() == TextAutoSizingValue::StillHasNodes::No; 5308 5298 }); 5309 addResult.iterator->value->addNode(node, candidateSize);5310 }5311 5312 void Document::validateAutoSizingNodes()5313 {5314 Vector<TextAutoSizingKey> nodesForRemoval;5315 for (auto& keyValuePair : m_textAutoSizedNodes) {5316 TextAutoSizingValue* value = keyValuePair.value.get();5317 // Update all the nodes in the collection to reflect the new5318 // candidate size.5319 value->adjustNodeSizes();5320 }5321 m_textAutoSizedNodes.removeIf([](auto& keyAndValue) {5322 return !keyAndValue.value->numNodes();5323 });5324 5299 } 5325 5300 5326 void Document::resetAutoSizingNodes() 5327 { 5328 for (auto& value : m_textAutoSizedNodes.values()) 5329 value->reset(); 5301 void Document::clearAutoSizedNodes() 5302 { 5330 5303 m_textAutoSizedNodes.clear(); 5331 5304 } -
trunk/Source/WebCore/dom/Document.h
r201496 r201534 47 47 #include "StyleChange.h" 48 48 #include "Supplementable.h" 49 #include "TextAutoSizing.h" 49 50 #include "TextResourceDecoder.h" 50 51 #include "Timer.h" … … 213 214 class TextAutoSizingKey; 214 215 class TextAutoSizingValue; 215 216 struct TextAutoSizingTraits : WTF::GenericHashTraits<TextAutoSizingKey> {217 static const bool emptyValueIsZero = true;218 static void constructDeletedValue(TextAutoSizingKey& slot);219 static bool isDeletedValue(const TextAutoSizingKey& value);220 };221 216 #endif 222 217 … … 1695 1690 #if ENABLE(IOS_TEXT_AUTOSIZING) 1696 1691 public: 1697 void addAutoSiz ingNode(Text&, float size);1698 void validateAutoSizingNodes();1699 void resetAutoSizingNodes();1692 void addAutoSizedNode(Text&, float size); 1693 void updateAutoSizedNodes(); 1694 void clearAutoSizedNodes(); 1700 1695 1701 1696 private: 1702 typedef HashMap<TextAutoSizingKey, RefPtr<TextAutoSizingValue>, TextAutoSizingHash, TextAutoSizingTraits> TextAutoSizingMap;1697 using TextAutoSizingMap = HashMap<TextAutoSizingKey, std::unique_ptr<TextAutoSizingValue>, TextAutoSizingHash, TextAutoSizingTraits>; 1703 1698 TextAutoSizingMap m_textAutoSizedNodes; 1704 1699 #endif -
trunk/Source/WebCore/rendering/RenderBlockFlow.cpp
r201205 r201534 3818 3818 float candidateNewSize = roundf(std::min(minFontSize, specifiedSize * lineTextMultiplier)); 3819 3819 if (candidateNewSize > specifiedSize && candidateNewSize != fontDescription.computedSize() && text.textNode() && oldStyle.textSizeAdjust().isAuto()) 3820 document().addAutoSiz ingNode(*text.textNode(), candidateNewSize);3820 document().addAutoSizedNode(*text.textNode(), candidateNewSize); 3821 3821 } 3822 3822 -
trunk/Source/WebCore/rendering/RenderElement.cpp
r201205 r201534 2215 2215 2216 2216 // Remove style from auto-sizing table that are no longer valid. 2217 document-> validateAutoSizingNodes();2217 document->updateAutoSizedNodes(); 2218 2218 } 2219 2219 … … 2226 2226 LOG(TextAutosizing, "RenderElement::resetTextAutosizing()"); 2227 2227 2228 document-> resetAutoSizingNodes();2228 document->clearAutoSizedNodes(); 2229 2229 2230 2230 Vector<int> depthStack; -
trunk/Source/WebCore/rendering/TextAutoSizing.cpp
r201104 r201534 49 49 50 50 TextAutoSizingKey::TextAutoSizingKey(DeletedTag) 51 : m_isDeleted(true) 52 { 53 } 54 55 TextAutoSizingKey::TextAutoSizingKey(const RenderStyle* style) 56 : m_style(style ? RenderStyle::clonePtr(*style) : nullptr) 57 { 58 } 59 60 int TextAutoSizingValue::numNodes() const 61 { 62 return m_autoSizedNodes.size(); 63 } 64 65 void TextAutoSizingValue::addNode(Text& node, float size) 51 { 52 HashTraits<std::unique_ptr<RenderStyle>>::constructDeletedValue(m_style); 53 } 54 55 TextAutoSizingKey::TextAutoSizingKey(const RenderStyle& style, unsigned hash) 56 : m_style(RenderStyle::clonePtr(style)) // FIXME: This seems very inefficient. 57 , m_hash(hash) 58 { 59 } 60 61 void TextAutoSizingValue::addTextNode(Text& node, float size) 66 62 { 67 63 node.renderer()->setCandidateComputedTextSize(size); … … 69 65 } 70 66 71 #define MAX_SCALE_INCREASE 1.7f 72 73 bool TextAutoSizingValue::adjustNodeSizes() 74 { 75 bool didRemoveObjects = false; 76 77 // Remove stale nodes. Nodes may have had their renderers detached. We'll 78 // also need to remove the style from the documents m_textAutoSizedNodes 79 // collection. Return true indicates we need to do that removal. 67 static const float maxScaleIncrease = 1.7f; 68 69 auto TextAutoSizingValue::adjustTextNodeSizes() -> StillHasNodes 70 { 71 // Remove stale nodes. Nodes may have had their renderers detached. We'll also need to remove the style from the documents m_textAutoSizedNodes 72 // collection. Return true indicates we need to do that removal. 80 73 Vector<Text*> nodesForRemoval; 81 for (auto& node : m_autoSizedNodes) { 82 auto* text = node->renderer(); 83 if (!text || !text->style().textSizeAdjust().isAuto() || !text->candidateComputedTextSize()) { 84 nodesForRemoval.append(node.get()); 85 didRemoveObjects = true; 86 } 74 for (auto& textNode : m_autoSizedNodes) { 75 auto* renderer = textNode->renderer(); 76 if (!renderer || !renderer->style().textSizeAdjust().isAuto() || !renderer->candidateComputedTextSize()) 77 nodesForRemoval.append(textNode.get()); 87 78 } 88 79 … … 90 81 m_autoSizedNodes.remove(node); 91 82 92 // If we only have one piece of text with the style on the page don't 93 // adjust it's size. 83 StillHasNodes stillHasNodes = m_autoSizedNodes.isEmpty() ? StillHasNodes::No : StillHasNodes::Yes; 84 85 // If we only have one piece of text with the style on the page don't adjust it's size. 94 86 if (m_autoSizedNodes.size() <= 1) 95 return didRemoveObjects;96 97 // Compute average size 87 return stillHasNodes; 88 89 // Compute average size. 98 90 float cumulativeSize = 0; 99 91 for (auto& node : m_autoSizedNodes) 100 92 cumulativeSize += node->renderer()->candidateComputedTextSize(); 101 93 102 float averageSize = roundf(cumulativeSize / m_autoSizedNodes.size());103 104 // Adjust sizes 94 float averageSize = std::round(cumulativeSize / m_autoSizedNodes.size()); 95 96 // Adjust sizes. 105 97 bool firstPass = true; 106 98 for (auto& node : m_autoSizedNodes) { 107 auto * text =node->renderer();108 if ( !text || text->style().fontDescription().computedSize() == averageSize)109 continue; 110 111 float specifiedSize = text->style().fontDescription().specifiedSize();99 auto& renderer = *node->renderer(); 100 if (renderer.style().fontDescription().computedSize() == averageSize) 101 continue; 102 103 float specifiedSize = renderer.style().fontDescription().specifiedSize(); 112 104 float scaleChange = averageSize / specifiedSize; 113 if (scaleChange > MAX_SCALE_INCREASE&& firstPass) {105 if (scaleChange > maxScaleIncrease && firstPass) { 114 106 firstPass = false; 115 averageSize = roundf(specifiedSize * MAX_SCALE_INCREASE);107 averageSize = std::round(specifiedSize * maxScaleIncrease); 116 108 scaleChange = averageSize / specifiedSize; 117 109 } … … 119 111 LOG(TextAutosizing, " adjust node size %p firstPass=%d averageSize=%f scaleChange=%f", node.get(), firstPass, averageSize, scaleChange); 120 112 121 auto* parentRenderer = text->parent();122 123 auto style = cloneRenderStyleWithState( text->style());113 auto* parentRenderer = renderer.parent(); 114 115 auto style = cloneRenderStyleWithState(renderer.style()); 124 116 auto fontDescription = style.fontDescription(); 125 117 fontDescription.setComputedSize(averageSize); … … 162 154 } 163 155 164 return didRemoveObjects; 156 return stillHasNodes; 157 } 158 159 TextAutoSizingValue::~TextAutoSizingValue() 160 { 161 reset(); 165 162 } 166 163 … … 168 165 { 169 166 for (auto& node : m_autoSizedNodes) { 170 auto* text= node->renderer();171 if (! text)172 continue; 173 174 auto* parentRenderer = text->parent();167 auto* renderer = node->renderer(); 168 if (!renderer) 169 continue; 170 171 auto* parentRenderer = renderer->parent(); 175 172 if (!parentRenderer) 176 173 continue; 177 174 178 175 // Reset the font size back to the original specified size 179 auto fontDescription = text->style().fontDescription();176 auto fontDescription = renderer->style().fontDescription(); 180 177 float originalSize = fontDescription.specifiedSize(); 181 178 if (fontDescription.computedSize() != originalSize) { 182 179 fontDescription.setComputedSize(originalSize); 183 auto style = cloneRenderStyleWithState( text->style());180 auto style = cloneRenderStyleWithState(renderer->style()); 184 181 style.setFontDescription(fontDescription); 185 182 style.fontCascade().update(&node->document().fontSelector()); -
trunk/Source/WebCore/rendering/TextAutoSizing.h
r201104 r201534 24 24 */ 25 25 26 #ifndef TextAutoSizing_h 27 #define TextAutoSizing_h 26 #pragma once 28 27 29 28 #if ENABLE(IOS_TEXT_AUTOSIZING) … … 39 38 class Text; 40 39 40 // FIXME: We can probably get rid of this class entirely and use std::unique_ptr<RenderStyle> as key 41 // as long as we use the right hash traits. 41 42 class TextAutoSizingKey { 42 43 public: … … 44 45 enum DeletedTag { Deleted }; 45 46 explicit TextAutoSizingKey(DeletedTag); 46 explicit TextAutoSizingKey(const RenderStyle*); 47 TextAutoSizingKey(TextAutoSizingKey&&) = default; 47 TextAutoSizingKey(const RenderStyle&, unsigned hash); 48 48 49 TextAutoSizingKey& operator=(TextAutoSizingKey&&) = default; 49 const RenderStyle* style() const { ASSERT(!isDeleted()); return m_style.get(); } 50 bool isDeleted() const { return HashTraits<std::unique_ptr<RenderStyle>>::isDeletedValue(m_style); } 50 51 51 const RenderStyle* style() const { return m_style.get(); } 52 inline bool isDeleted() const { return m_isDeleted; } 52 unsigned hash() const { return m_hash; } 53 53 54 54 private: 55 55 std::unique_ptr<RenderStyle> m_style; 56 bool m_isDeleted { false};56 unsigned m_hash { 0 }; 57 57 }; 58 58 … … 63 63 if (!a.style() || !b.style()) 64 64 return a.style() == b.style(); 65 return a.style()->equalForTextAutosizing( b.style());65 return a.style()->equalForTextAutosizing(*b.style()); 66 66 } 67 67 68 68 struct TextAutoSizingHash { 69 static unsigned hash(const TextAutoSizingKey& key) { return key. style()->hashForTextAutosizing(); }69 static unsigned hash(const TextAutoSizingKey& key) { return key.hash(); } 70 70 static bool equal(const TextAutoSizingKey& a, const TextAutoSizingKey& b) { return a == b; } 71 71 static const bool safeToCompareToEmptyOrDeleted = true; 72 72 }; 73 73 74 class TextAutoSizingValue : public RefCounted<TextAutoSizingValue> {75 public: 76 static Ref<TextAutoSizingValue> create()74 struct TextAutoSizingTraits : WTF::GenericHashTraits<TextAutoSizingKey> { 75 static const bool emptyValueIsZero = true; 76 static void constructDeletedValue(TextAutoSizingKey& slot) 77 77 { 78 return adoptRef(*new TextAutoSizingValue); 78 new (NotNull, &slot) TextAutoSizingKey(TextAutoSizingKey::Deleted); 79 } 80 static bool isDeletedValue(const TextAutoSizingKey& value) 81 { 82 return value.isDeleted(); 83 } 84 }; 85 86 struct TextAutoSizingHashTranslator { 87 static unsigned hash(const RenderStyle& style) 88 { 89 return style.hashForTextAutosizing(); 79 90 } 80 91 81 void addNode(Text&, float size); 82 bool adjustNodeSizes(); 83 int numNodes() const; 92 static bool equal(const TextAutoSizingKey& key, const RenderStyle& style) 93 { 94 if (key.isDeleted() || !key.style()) 95 return false; 96 return key.style()->equalForTextAutosizing(style); 97 } 98 99 static void translate(TextAutoSizingKey& key, const RenderStyle& style, unsigned hash) 100 { 101 key = { style, hash }; 102 } 103 }; 104 105 class TextAutoSizingValue { 106 WTF_MAKE_FAST_ALLOCATED; 107 public: 108 TextAutoSizingValue() = default; 109 ~TextAutoSizingValue(); 110 111 void addTextNode(Text&, float size); 112 113 enum class StillHasNodes { No, Yes }; 114 StillHasNodes adjustTextNodeSizes(); 115 116 private: 84 117 void reset(); 85 private: 86 TextAutoSizingValue() { } 118 87 119 HashSet<RefPtr<Text>> m_autoSizedNodes; 88 120 }; … … 91 123 92 124 #endif // ENABLE(IOS_TEXT_AUTOSIZING) 93 94 #endif // TextAutoSizing_h -
trunk/Source/WebCore/rendering/style/RenderStyle.cpp
r201498 r201534 412 412 } 413 413 414 bool RenderStyle::equalForTextAutosizing(const RenderStyle *other) const415 { 416 return rareNonInheritedData->m_appearance == other ->rareNonInheritedData->m_appearance417 && rareNonInheritedData->marginBeforeCollapse == other ->rareNonInheritedData->marginBeforeCollapse418 && rareNonInheritedData->marginAfterCollapse == other ->rareNonInheritedData->marginAfterCollapse419 && rareNonInheritedData->lineClamp == other ->rareNonInheritedData->lineClamp420 && rareInheritedData->textSizeAdjust == other ->rareInheritedData->textSizeAdjust421 && rareInheritedData->overflowWrap == other ->rareInheritedData->overflowWrap422 && rareInheritedData->nbspMode == other ->rareInheritedData->nbspMode423 && rareInheritedData->lineBreak == other ->rareInheritedData->lineBreak424 && rareInheritedData->textSecurity == other ->rareInheritedData->textSecurity425 && inherited->specifiedLineHeight == other ->inherited->specifiedLineHeight426 && inherited->fontCascade.equalForTextAutoSizing(other ->inherited->fontCascade)427 && inherited->horizontal_border_spacing == other ->inherited->horizontal_border_spacing428 && inherited->vertical_border_spacing == other ->inherited->vertical_border_spacing429 && inherited_flags._box_direction == other ->inherited_flags._box_direction430 && inherited_flags.m_rtlOrdering == other ->inherited_flags.m_rtlOrdering431 && noninherited_flags.position() == other ->noninherited_flags.position()432 && noninherited_flags.floating() == other ->noninherited_flags.floating()433 && rareNonInheritedData->textOverflow == other ->rareNonInheritedData->textOverflow;414 bool RenderStyle::equalForTextAutosizing(const RenderStyle& other) const 415 { 416 return rareNonInheritedData->m_appearance == other.rareNonInheritedData->m_appearance 417 && rareNonInheritedData->marginBeforeCollapse == other.rareNonInheritedData->marginBeforeCollapse 418 && rareNonInheritedData->marginAfterCollapse == other.rareNonInheritedData->marginAfterCollapse 419 && rareNonInheritedData->lineClamp == other.rareNonInheritedData->lineClamp 420 && rareInheritedData->textSizeAdjust == other.rareInheritedData->textSizeAdjust 421 && rareInheritedData->overflowWrap == other.rareInheritedData->overflowWrap 422 && rareInheritedData->nbspMode == other.rareInheritedData->nbspMode 423 && rareInheritedData->lineBreak == other.rareInheritedData->lineBreak 424 && rareInheritedData->textSecurity == other.rareInheritedData->textSecurity 425 && inherited->specifiedLineHeight == other.inherited->specifiedLineHeight 426 && inherited->fontCascade.equalForTextAutoSizing(other.inherited->fontCascade) 427 && inherited->horizontal_border_spacing == other.inherited->horizontal_border_spacing 428 && inherited->vertical_border_spacing == other.inherited->vertical_border_spacing 429 && inherited_flags._box_direction == other.inherited_flags._box_direction 430 && inherited_flags.m_rtlOrdering == other.inherited_flags.m_rtlOrdering 431 && noninherited_flags.position() == other.noninherited_flags.position() 432 && noninherited_flags.floating() == other.noninherited_flags.floating() 433 && rareNonInheritedData->textOverflow == other.rareNonInheritedData->textOverflow; 434 434 } 435 435 -
trunk/Source/WebCore/rendering/style/RenderStyle.h
r201498 r201534 1863 1863 #if ENABLE(IOS_TEXT_AUTOSIZING) 1864 1864 uint32_t hashForTextAutosizing() const; 1865 bool equalForTextAutosizing(const RenderStyle *other) const;1865 bool equalForTextAutosizing(const RenderStyle&) const; 1866 1866 #endif 1867 1867
Note:
See TracChangeset
for help on using the changeset viewer.