diff options
author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-06-20 13:01:08 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-06-20 13:01:08 +0200 |
commit | 49233e234e5c787396cadb2cea33b31ae0cd65c1 (patch) | |
tree | 5410cb9a8fd53168bb60d62c54b654d86f03c38d /Source/WebCore/dom/NodeRenderingContext.cpp | |
parent | b211c645d8ab690f713515dfdc84d80b11c27d2c (diff) | |
download | qtwebkit-49233e234e5c787396cadb2cea33b31ae0cd65c1.tar.gz |
Imported WebKit commit 3a8c29f35d00659d2ce7a0ccdfa8304f14e82327 (http://svn.webkit.org/repository/webkit/trunk@120813)
New snapshot with Windows build fixes
Diffstat (limited to 'Source/WebCore/dom/NodeRenderingContext.cpp')
-rw-r--r-- | Source/WebCore/dom/NodeRenderingContext.cpp | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/Source/WebCore/dom/NodeRenderingContext.cpp b/Source/WebCore/dom/NodeRenderingContext.cpp index 7f70e7c0f..b4d6d4686 100644 --- a/Source/WebCore/dom/NodeRenderingContext.cpp +++ b/Source/WebCore/dom/NodeRenderingContext.cpp @@ -55,6 +55,7 @@ NodeRenderingContext::NodeRenderingContext(Node* node) : m_phase(AttachingNotInTree) , m_node(node) , m_parentNodeForRenderingAndStyle(0) + , m_resetStyleInheritance(false) , m_visualParentShadow(0) , m_insertionPoint(0) , m_style(0) @@ -67,6 +68,7 @@ NodeRenderingContext::NodeRenderingContext(Node* node) if (parent->isShadowRoot() && toShadowRoot(parent)->isYoungest()) { m_phase = AttachingShadowChild; m_parentNodeForRenderingAndStyle = toShadowRoot(parent)->host(); + m_resetStyleInheritance = toShadowRoot(parent)->resetStyleInheritance(); return; } @@ -82,7 +84,9 @@ NodeRenderingContext::NodeRenderingContext(Node* node) if ((m_insertionPoint = m_visualParentShadow->insertionPointFor(m_node))) { if (m_insertionPoint->shadowRoot()->isUsedForRendering()) { m_phase = AttachingDistributed; - m_parentNodeForRenderingAndStyle = NodeRenderingContext(m_insertionPoint).parentNodeForRenderingAndStyle(); + NodeRenderingContext insertionPointContext(m_insertionPoint); + m_parentNodeForRenderingAndStyle = insertionPointContext.parentNodeForRenderingAndStyle(); + m_resetStyleInheritance = insertionPointContext.resetStyleInheritance(); return; } } @@ -107,9 +111,11 @@ NodeRenderingContext::NodeRenderingContext(Node* node) else m_phase = AttachingFallbacked; - if (toInsertionPoint(parent)->isActive()) - m_parentNodeForRenderingAndStyle = NodeRenderingContext(parent).parentNodeForRenderingAndStyle(); - else + if (toInsertionPoint(parent)->isActive()) { + NodeRenderingContext parentContext(parent); + m_parentNodeForRenderingAndStyle = parentContext.parentNodeForRenderingAndStyle(); + m_resetStyleInheritance = parentContext.resetStyleInheritance(); + } else m_parentNodeForRenderingAndStyle = parent; return; } @@ -123,6 +129,7 @@ NodeRenderingContext::NodeRenderingContext(Node* node, RenderStyle* style) : m_phase(Calculating) , m_node(node) , m_parentNodeForRenderingAndStyle(0) + , m_resetStyleInheritance(false) , m_visualParentShadow(0) , m_insertionPoint(0) , m_style(style) |