Index: third_party/WebKit/Source/core/dom/Document.h |
diff --git a/third_party/WebKit/Source/core/dom/Document.h b/third_party/WebKit/Source/core/dom/Document.h |
index 8e2379b87dbb9f46de569918391676782f842009..99ac211f8e1c1e51c2c72a19d5abb6bb48bfb827 100644 |
--- a/third_party/WebKit/Source/core/dom/Document.h |
+++ b/third_party/WebKit/Source/core/dom/Document.h |
@@ -41,6 +41,7 @@ |
#include "core/dom/DocumentTiming.h" |
#include "core/dom/ExecutionContext.h" |
#include "core/dom/MutationObserver.h" |
+#include "core/dom/Text.h" |
#include "core/dom/TextLinkColors.h" |
#include "core/dom/TreeScope.h" |
#include "core/dom/UserActionElementSet.h" |
@@ -51,6 +52,7 @@ |
#include "core/frame/HostsUsingFeatures.h" |
#include "core/html/parser/ParserSynchronizationPolicy.h" |
#include "core/page/PageVisibilityState.h" |
+#include "core/style/ComputedStyle.h" |
#include "platform/Length.h" |
#include "platform/Timer.h" |
#include "platform/weborigin/KURL.h" |
@@ -159,7 +161,6 @@ class StringOrDictionary; |
class StyleEngine; |
class StyleResolver; |
class StyleSheetList; |
-class Text; |
class TextAutosizer; |
class Touch; |
class TouchList; |
@@ -251,6 +252,17 @@ enum WouldLoadReason { |
WouldLoadReasonEnd |
}; |
+struct StyleRecalcData : public GarbageCollectedFinalized<StyleRecalcData> { |
rune
2016/11/07 09:43:19
This is only used for reattachment, right? How abo
|
+ StyleRecalcData(RefPtr<ComputedStyle> computedStyle, Text* nextTextSibling) |
+ : computedStyle(std::move(computedStyle)), |
+ nextTextSibling(nextTextSibling) {} |
+ |
+ RefPtr<ComputedStyle> computedStyle; |
+ Member<Text> nextTextSibling; |
+ |
+ DEFINE_INLINE_TRACE() { visitor->trace(nextTextSibling); } |
+}; |
+ |
using DocumentClassFlags = unsigned char; |
class CORE_EXPORT Document : public ContainerNode, |
@@ -345,8 +357,8 @@ class CORE_EXPORT Document : public ContainerNode, |
Range* caretRangeFromPoint(int x, int y); |
Element* scrollingElement(); |
- void addNonAttachedStyle(Element&, RefPtr<ComputedStyle>); |
- ComputedStyle* getNonAttachedStyle(Element&); |
+ void addStyleRecalcData(Element&, StyleRecalcData*); |
+ StyleRecalcData* getStyleRecalcData(Element&); |
String readyState() const; |
@@ -1450,7 +1462,7 @@ class CORE_EXPORT Document : public ContainerNode, |
Member<DocumentParser> m_parser; |
Member<ContextFeatures> m_contextFeatures; |
- HeapHashMap<Member<Element>, RefPtr<ComputedStyle>> m_nonAttachedStyle; |
+ HeapHashMap<Member<Element>, Member<StyleRecalcData>> m_styleRecalcDataMap; |
esprehn
2016/11/07 22:26:26
HeapHashMap<Member<Element>, StyleRecalcData>
tha
|
bool m_wellFormed; |