<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[209756] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/209756">209756</a></dd>
<dt>Author</dt> <dd>antti@apple.com</dd>
<dt>Date</dt> <dd>2016-12-13 08:08:04 -0800 (Tue, 13 Dec 2016)</dd>
</dl>

<h3>Log Message</h3>
<pre>Source/WebCore:
REGRESSION (<a href="http://trac.webkit.org/projects/webkit/changeset/198990">r198990</a>): Cannot edit content inside &lt;details&gt; in wysiwyg editor
https://bugs.webkit.org/show_bug.cgi?id=165757

Reviewed by Andreas Kling.

Test: fast/html/details-edit.html

-webkit-user-modify is reset on shadow boundary so it doesn't go through &lt;details&gt; shadow tree.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::styleForElement):
(WebCore::StyleResolver::pseudoStyleForElement):
(WebCore::StyleResolver::styleForPage):
(WebCore::StyleResolver::applyMatchedProperties):
* dom/Node.cpp:
(WebCore::computeEditabilityFromComputedStyle):
(WebCore::Node::computeEditability):

    Make -webkit-user-modify (which we would want to get rid of completely eventually) have no effect in shadow trees.
    Check for contenteditable directly instead.

* html/HTMLInputElement.cpp:
(WebCore::HTMLInputElement::createInnerTextStyle):
* html/HTMLTextAreaElement.cpp:
(WebCore::HTMLTextAreaElement::createInnerTextStyle):
* html/shadow/TextControlInnerElements.cpp:
* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::createFlowThreadStyle):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::calculateClipRects):
* rendering/RenderListItem.cpp:
(WebCore::RenderListItem::styleDidChange):
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::createAnonymousStyleWithDisplay):
(WebCore::RenderStyle::createStyleInheritingFromPseudoStyle):
(WebCore::RenderStyle::inheritFrom):

    Let -webkit-user-modify inherit through shadow boundary as normal.

* rendering/style/RenderStyle.h:

LayoutTests:
REGRESSION (<a href="http://trac.webkit.org/projects/webkit/changeset/198990">r198990</a>): Safari - Cannot edit content inside &lt;details&gt; in wysiwyg editor
https://bugs.webkit.org/show_bug.cgi?id=165757

Reviewed by Andreas Kling.

* editing/execCommand/justify-right-then-indent-with-problematic-body-expected.txt:
* fast/html/details-edit-expected.txt: Added.
* fast/html/details-edit.html: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestseditingexecCommandjustifyrightthenindentwithproblematicbodyexpectedtxt">trunk/LayoutTests/editing/execCommand/justify-right-then-indent-with-problematic-body-expected.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorecssStyleResolvercpp">trunk/Source/WebCore/css/StyleResolver.cpp</a></li>
<li><a href="#trunkSourceWebCoredomNodecpp">trunk/Source/WebCore/dom/Node.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLInputElementcpp">trunk/Source/WebCore/html/HTMLInputElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLTextAreaElementcpp">trunk/Source/WebCore/html/HTMLTextAreaElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlshadowTextControlInnerElementscpp">trunk/Source/WebCore/html/shadow/TextControlInnerElements.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderFlowThreadcpp">trunk/Source/WebCore/rendering/RenderFlowThread.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderLayercpp">trunk/Source/WebCore/rendering/RenderLayer.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderListItemcpp">trunk/Source/WebCore/rendering/RenderListItem.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleRenderStylecpp">trunk/Source/WebCore/rendering/style/RenderStyle.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleRenderStyleh">trunk/Source/WebCore/rendering/style/RenderStyle.h</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsfasthtmldetailseditexpectedtxt">trunk/LayoutTests/fast/html/details-edit-expected.txt</a></li>
<li><a href="#trunkLayoutTestsfasthtmldetailsedithtml">trunk/LayoutTests/fast/html/details-edit.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/LayoutTests/ChangeLog        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -1,3 +1,14 @@
</span><ins>+2016-12-13  Antti Koivisto  &lt;antti@apple.com&gt;
+
+        REGRESSION (r198990): Safari - Cannot edit content inside &lt;details&gt; in wysiwyg editor
+        https://bugs.webkit.org/show_bug.cgi?id=165757
+
+        Reviewed by Andreas Kling.
+
+        * editing/execCommand/justify-right-then-indent-with-problematic-body-expected.txt:
+        * fast/html/details-edit-expected.txt: Added.
+        * fast/html/details-edit.html: Added.
+
</ins><span class="cx"> 2016-12-13  Per Arne Vollan  &lt;pvollan@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Unreviewed test gardening.
</span></span></pre></div>
<a id="trunkLayoutTestseditingexecCommandjustifyrightthenindentwithproblematicbodyexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/editing/execCommand/justify-right-then-indent-with-problematic-body-expected.txt (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/editing/execCommand/justify-right-then-indent-with-problematic-body-expected.txt        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/LayoutTests/editing/execCommand/justify-right-then-indent-with-problematic-body-expected.txt        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -1,4 +1,2 @@
</span><span class="cx"> Pass.
</span><del>-
</del><span class="cx"> WebKit didn't Crash.
</span><del>-
</del></span></pre></div>
<a id="trunkLayoutTestsfasthtmldetailseditexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/html/details-edit-expected.txt (0 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/html/details-edit-expected.txt                                (rev 0)
+++ trunk/LayoutTests/fast/html/details-edit-expected.txt        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+PASS
</ins></span></pre></div>
<a id="trunkLayoutTestsfasthtmldetailsedithtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/html/details-edit.html (0 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/html/details-edit.html                                (rev 0)
+++ trunk/LayoutTests/fast/html/details-edit.html        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -0,0 +1,15 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;script&gt;
+if (window.testRunner)
+    testRunner.dumpAsText();
+&lt;/script&gt;
+&lt;body contenteditable&gt;
+&lt;details open&gt;
+&lt;p&gt;FAIL&lt;/p&gt;
+&lt;/details&gt;
+&lt;script&gt;
+var p = document.querySelector(&quot;p&quot;);
+var selection = window.getSelection();
+selection.selectAllChildren(p);
+document.execCommand(&quot;InsertText&quot;, false, &quot;PASS&quot;);
+&lt;/script&gt;
</ins></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/ChangeLog        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -1,3 +1,46 @@
</span><ins>+2016-12-13  Antti Koivisto  &lt;antti@apple.com&gt;
+
+        REGRESSION (r198990): Cannot edit content inside &lt;details&gt; in wysiwyg editor
+        https://bugs.webkit.org/show_bug.cgi?id=165757
+
+        Reviewed by Andreas Kling.
+
+        Test: fast/html/details-edit.html
+
+        -webkit-user-modify is reset on shadow boundary so it doesn't go through &lt;details&gt; shadow tree.
+
+        * css/StyleResolver.cpp:
+        (WebCore::StyleResolver::styleForElement):
+        (WebCore::StyleResolver::pseudoStyleForElement):
+        (WebCore::StyleResolver::styleForPage):
+        (WebCore::StyleResolver::applyMatchedProperties):
+        * dom/Node.cpp:
+        (WebCore::computeEditabilityFromComputedStyle):
+        (WebCore::Node::computeEditability):
+
+            Make -webkit-user-modify (which we would want to get rid of completely eventually) have no effect in shadow trees.
+            Check for contenteditable directly instead.
+
+        * html/HTMLInputElement.cpp:
+        (WebCore::HTMLInputElement::createInnerTextStyle):
+        * html/HTMLTextAreaElement.cpp:
+        (WebCore::HTMLTextAreaElement::createInnerTextStyle):
+        * html/shadow/TextControlInnerElements.cpp:
+        * rendering/RenderFlowThread.cpp:
+        (WebCore::RenderFlowThread::createFlowThreadStyle):
+        * rendering/RenderLayer.cpp:
+        (WebCore::RenderLayer::calculateClipRects):
+        * rendering/RenderListItem.cpp:
+        (WebCore::RenderListItem::styleDidChange):
+        * rendering/style/RenderStyle.cpp:
+        (WebCore::RenderStyle::createAnonymousStyleWithDisplay):
+        (WebCore::RenderStyle::createStyleInheritingFromPseudoStyle):
+        (WebCore::RenderStyle::inheritFrom):
+
+            Let -webkit-user-modify inherit through shadow boundary as normal.
+
+        * rendering/style/RenderStyle.h:
+
</ins><span class="cx"> 2016-12-12  Darin Adler  &lt;darin@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Remove bindings generation support for legacy WebCore::Dictionary
</span></span></pre></div>
<a id="trunkSourceWebCorecssStyleResolvercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/StyleResolver.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/StyleResolver.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/css/StyleResolver.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -393,7 +393,7 @@
</span><span class="cx"> 
</span><span class="cx">     if (state.parentStyle()) {
</span><span class="cx">         state.setStyle(RenderStyle::createPtr());
</span><del>-        state.style()-&gt;inheritFrom(state.parentStyle(), isAtShadowBoundary(element) ? RenderStyle::AtShadowBoundary : RenderStyle::NotAtShadowBoundary);
</del><ins>+        state.style()-&gt;inheritFrom(*state.parentStyle());
</ins><span class="cx">     } else {
</span><span class="cx">         state.setStyle(defaultStyleForElement());
</span><span class="cx">         state.setParentStyle(RenderStyle::clonePtr(*state.style()));
</span><span class="lines">@@ -605,7 +605,7 @@
</span><span class="cx"> 
</span><span class="cx">     if (m_state.parentStyle()) {
</span><span class="cx">         state.setStyle(RenderStyle::createPtr());
</span><del>-        state.style()-&gt;inheritFrom(m_state.parentStyle());
</del><ins>+        state.style()-&gt;inheritFrom(*m_state.parentStyle());
</ins><span class="cx">     } else {
</span><span class="cx">         state.setStyle(defaultStyleForElement());
</span><span class="cx">         state.setParentStyle(RenderStyle::clonePtr(*state.style()));
</span><span class="lines">@@ -655,7 +655,7 @@
</span><span class="cx">     m_state = State(*documentElement, m_document.renderStyle());
</span><span class="cx"> 
</span><span class="cx">     m_state.setStyle(RenderStyle::createPtr());
</span><del>-    m_state.style()-&gt;inheritFrom(m_state.rootElementStyle());
</del><ins>+    m_state.style()-&gt;inheritFrom(*m_state.rootElementStyle());
</ins><span class="cx"> 
</span><span class="cx">     PageRuleCollector collector(m_state, m_ruleSets);
</span><span class="cx">     collector.matchAllPageRules(pageIndex);
</span><span class="lines">@@ -1338,7 +1338,7 @@
</span><span class="cx">             EInsideLink linkStatus = state.style()-&gt;insideLink();
</span><span class="cx">             // If the cache item parent style has identical inherited properties to the current parent style then the
</span><span class="cx">             // resulting style will be identical too. We copy the inherited properties over from the cache and are done.
</span><del>-            state.style()-&gt;inheritFrom(cacheItem-&gt;renderStyle.get());
</del><ins>+            state.style()-&gt;inheritFrom(*cacheItem-&gt;renderStyle);
</ins><span class="cx"> 
</span><span class="cx">             // Unfortunately the link status is treated like an inherited property. We need to explicitly restore it.
</span><span class="cx">             state.style()-&gt;setInsideLink(linkStatus);
</span></span></pre></div>
<a id="trunkSourceWebCoredomNodecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/dom/Node.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/dom/Node.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/dom/Node.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -701,7 +701,10 @@
</span><span class="cx">     if (!document().hasLivingRenderTree() || isPseudoElement())
</span><span class="cx">         return Editability::ReadOnly;
</span><span class="cx"> 
</span><del>-    if (document().frame() &amp;&amp; document().frame()-&gt;page() &amp;&amp; document().frame()-&gt;page()-&gt;isEditable() &amp;&amp; !containingShadowRoot())
</del><ins>+    if (isInShadowTree())
+        return HTMLElement::editabilityFromContentEditableAttr(*this);
+
+    if (document().frame() &amp;&amp; document().frame()-&gt;page() &amp;&amp; document().frame()-&gt;page()-&gt;isEditable())
</ins><span class="cx">         return Editability::CanEditRichly;
</span><span class="cx"> 
</span><span class="cx">     if (shouldUpdateStyle == ShouldUpdateStyle::Update &amp;&amp; document().needsStyleRecalc()) {
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLInputElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLInputElement.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLInputElement.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/html/HTMLInputElement.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -1948,7 +1948,7 @@
</span><span class="cx"> RenderStyle HTMLInputElement::createInnerTextStyle(const RenderStyle&amp; style) const
</span><span class="cx"> {
</span><span class="cx">     auto textBlockStyle = RenderStyle::create();
</span><del>-    textBlockStyle.inheritFrom(&amp;style);
</del><ins>+    textBlockStyle.inheritFrom(style);
</ins><span class="cx">     adjustInnerTextStyle(style, textBlockStyle);
</span><span class="cx"> 
</span><span class="cx">     textBlockStyle.setWhiteSpace(PRE);
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLTextAreaElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLTextAreaElement.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLTextAreaElement.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/html/HTMLTextAreaElement.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -569,7 +569,7 @@
</span><span class="cx"> RenderStyle HTMLTextAreaElement::createInnerTextStyle(const RenderStyle&amp; style) const
</span><span class="cx"> {
</span><span class="cx">     auto textBlockStyle = RenderStyle::create();
</span><del>-    textBlockStyle.inheritFrom(&amp;style);
</del><ins>+    textBlockStyle.inheritFrom(style);
</ins><span class="cx">     adjustInnerTextStyle(style, textBlockStyle);
</span><span class="cx">     textBlockStyle.setDisplay(BLOCK);
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlshadowTextControlInnerElementscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/shadow/TextControlInnerElements.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/shadow/TextControlInnerElements.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/html/shadow/TextControlInnerElements.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -78,7 +78,7 @@
</span><span class="cx"> std::optional&lt;ElementStyle&gt; TextControlInnerElement::resolveCustomStyle(const RenderStyle&amp;, const RenderStyle* shadowHostStyle)
</span><span class="cx"> {
</span><span class="cx">     auto innerContainerStyle = RenderStyle::createPtr();
</span><del>-    innerContainerStyle-&gt;inheritFrom(shadowHostStyle);
</del><ins>+    innerContainerStyle-&gt;inheritFrom(*shadowHostStyle);
</ins><span class="cx"> 
</span><span class="cx">     innerContainerStyle-&gt;setFlexGrow(1);
</span><span class="cx">     // min-width: 0; is needed for correct shrinking.
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderFlowThreadcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderFlowThread.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderFlowThread.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/rendering/RenderFlowThread.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -71,7 +71,7 @@
</span><span class="cx"> RenderStyle RenderFlowThread::createFlowThreadStyle(const RenderStyle* parentStyle)
</span><span class="cx"> {
</span><span class="cx">     auto newStyle = RenderStyle::create();
</span><del>-    newStyle.inheritFrom(parentStyle);
</del><ins>+    newStyle.inheritFrom(*parentStyle);
</ins><span class="cx">     newStyle.setDisplay(BLOCK);
</span><span class="cx">     newStyle.setPosition(AbsolutePosition);
</span><span class="cx">     newStyle.setZIndex(0);
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderLayercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderLayer.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderLayer.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/rendering/RenderLayer.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -6935,7 +6935,7 @@
</span><span class="cx"> RenderStyle RenderLayer::createReflectionStyle()
</span><span class="cx"> {
</span><span class="cx">     auto newStyle = RenderStyle::create();
</span><del>-    newStyle.inheritFrom(&amp;renderer().style());
</del><ins>+    newStyle.inheritFrom(renderer().style());
</ins><span class="cx">     
</span><span class="cx">     // Map in our transform.
</span><span class="cx">     TransformOperations transform;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderListItemcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderListItem.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderListItem.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/rendering/RenderListItem.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -79,7 +79,7 @@
</span><span class="cx">     auto newStyle = RenderStyle::create();
</span><span class="cx">     // The marker always inherits from the list item, regardless of where it might end
</span><span class="cx">     // up (e.g., in some deeply nested line box). See CSS3 spec.
</span><del>-    newStyle.inheritFrom(&amp;style());
</del><ins>+    newStyle.inheritFrom(style());
</ins><span class="cx">     if (!m_marker) {
</span><span class="cx">         m_marker = createRenderer&lt;RenderListMarker&gt;(*this, WTFMove(newStyle)).leakPtr();
</span><span class="cx">         m_marker-&gt;initializeStyle();
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleRenderStylecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/RenderStyle.cpp (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/RenderStyle.cpp        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/rendering/style/RenderStyle.cpp        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -112,7 +112,7 @@
</span><span class="cx"> RenderStyle RenderStyle::createAnonymousStyleWithDisplay(const RenderStyle&amp; parentStyle, EDisplay display)
</span><span class="cx"> {
</span><span class="cx">     auto newStyle = create();
</span><del>-    newStyle.inheritFrom(&amp;parentStyle);
</del><ins>+    newStyle.inheritFrom(parentStyle);
</ins><span class="cx">     newStyle.inheritUnicodeBidiFrom(&amp;parentStyle);
</span><span class="cx">     newStyle.setDisplay(display);
</span><span class="cx">     return newStyle;
</span><span class="lines">@@ -123,7 +123,7 @@
</span><span class="cx">     ASSERT(pseudoStyle.styleType() == BEFORE || pseudoStyle.styleType() == AFTER);
</span><span class="cx"> 
</span><span class="cx">     auto style = create();
</span><del>-    style.inheritFrom(&amp;pseudoStyle);
</del><ins>+    style.inheritFrom(pseudoStyle);
</ins><span class="cx">     return style;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -267,20 +267,14 @@
</span><span class="cx">     return resolvedContentAlignmentDistribution(alignContent(), normalValueBehavior);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void RenderStyle::inheritFrom(const RenderStyle* inheritParent, IsAtShadowBoundary isAtShadowBoundary)
</del><ins>+void RenderStyle::inheritFrom(const RenderStyle&amp; inheritParent)
</ins><span class="cx"> {
</span><del>-    if (isAtShadowBoundary == AtShadowBoundary) {
-        // Even if surrounding content is user-editable, shadow DOM should act as a single unit, and not necessarily be editable
-        EUserModify currentUserModify = userModify();
-        rareInheritedData = inheritParent-&gt;rareInheritedData;
-        setUserModify(currentUserModify);
-    } else
-        rareInheritedData = inheritParent-&gt;rareInheritedData;
-    inherited = inheritParent-&gt;inherited;
-    inherited_flags = inheritParent-&gt;inherited_flags;
</del><ins>+    rareInheritedData = inheritParent.rareInheritedData;
+    inherited = inheritParent.inherited;
+    inherited_flags = inheritParent.inherited_flags;
</ins><span class="cx"> 
</span><del>-    if (m_svgStyle != inheritParent-&gt;m_svgStyle)
-        m_svgStyle.access()-&gt;inheritFrom(inheritParent-&gt;m_svgStyle.get());
</del><ins>+    if (m_svgStyle != inheritParent.m_svgStyle)
+        m_svgStyle.access()-&gt;inheritFrom(inheritParent.m_svgStyle.get());
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void RenderStyle::copyNonInheritedFrom(const RenderStyle* other)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleRenderStyleh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/RenderStyle.h (209755 => 209756)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/RenderStyle.h        2016-12-13 12:49:20 UTC (rev 209755)
+++ trunk/Source/WebCore/rendering/style/RenderStyle.h        2016-12-13 16:08:04 UTC (rev 209756)
</span><span class="lines">@@ -510,12 +510,7 @@
</span><span class="cx">     StyleSelfAlignmentData resolvedJustifyItems(ItemPosition normalValueBehaviour) const;
</span><span class="cx">     StyleSelfAlignmentData resolvedJustifySelf(const RenderStyle&amp; parentStyle, ItemPosition normalValueBehaviour) const;
</span><span class="cx"> 
</span><del>-    enum IsAtShadowBoundary {
-        AtShadowBoundary,
-        NotAtShadowBoundary,
-    };
-
-    void inheritFrom(const RenderStyle* inheritParent, IsAtShadowBoundary = NotAtShadowBoundary);
</del><ins>+    void inheritFrom(const RenderStyle&amp; inheritParent);
</ins><span class="cx">     void copyNonInheritedFrom(const RenderStyle*);
</span><span class="cx"> 
</span><span class="cx">     PseudoId styleType() const { return noninherited_flags.styleType(); }
</span></span></pre>
</div>
</div>

</body>
</html>