<!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>[163751] trunk/Source/WebCore</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/163751">163751</a></dd>
<dt>Author</dt> <dd>zandobersek@gmail.com</dd>
<dt>Date</dt> <dd>2014-02-09 04:11:01 -0800 (Sun, 09 Feb 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Manage ShadowData through std::unique_ptr
https://bugs.webkit.org/show_bug.cgi?id=128466

Reviewed by Andreas Kling.

Use std::unique_ptr instead of OwnPtr to manage ShadowData objects.

* css/SVGCSSStyleSelector.cpp:
(WebCore::StyleResolver::applySVGProperty):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):
* page/animation/CSSPropertyAnimation.cpp:
(WebCore::blendFunc):
(WebCore::PropertyWrapperShadow::PropertyWrapperShadow):
(WebCore::PropertyWrapperShadow::blendSimpleOrMatchedShadowLists):
(WebCore::PropertyWrapperShadow::blendMismatchedShadowLists):
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::setTextShadow):
(WebCore::RenderStyle::setBoxShadow):
* rendering/style/RenderStyle.h:
* rendering/style/SVGRenderStyle.h:
(WebCore::SVGRenderStyle::setShadow):
* rendering/style/SVGRenderStyleDefs.cpp:
(WebCore::StyleShadowSVGData::StyleShadowSVGData):
* rendering/style/SVGRenderStyleDefs.h:
* rendering/style/ShadowData.cpp:
(WebCore::ShadowData::ShadowData):
* rendering/style/ShadowData.h:
(WebCore::ShadowData::setNext):
* rendering/style/StyleRareInheritedData.cpp:
(WebCore::StyleRareInheritedData::StyleRareInheritedData):
* rendering/style/StyleRareInheritedData.h:
* rendering/style/StyleRareNonInheritedData.cpp:
(WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
* rendering/style/StyleRareNonInheritedData.h:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorecssSVGCSSStyleSelectorcpp">trunk/Source/WebCore/css/SVGCSSStyleSelector.cpp</a></li>
<li><a href="#trunkSourceWebCorecssStyleResolvercpp">trunk/Source/WebCore/css/StyleResolver.cpp</a></li>
<li><a href="#trunkSourceWebCorepageanimationCSSPropertyAnimationcpp">trunk/Source/WebCore/page/animation/CSSPropertyAnimation.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>
<li><a href="#trunkSourceWebCorerenderingstyleSVGRenderStyleh">trunk/Source/WebCore/rendering/style/SVGRenderStyle.h</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleSVGRenderStyleDefscpp">trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleSVGRenderStyleDefsh">trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.h</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleShadowDatacpp">trunk/Source/WebCore/rendering/style/ShadowData.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleShadowDatah">trunk/Source/WebCore/rendering/style/ShadowData.h</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleStyleRareInheritedDatacpp">trunk/Source/WebCore/rendering/style/StyleRareInheritedData.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleStyleRareInheritedDatah">trunk/Source/WebCore/rendering/style/StyleRareInheritedData.h</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleStyleRareNonInheritedDatacpp">trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleStyleRareNonInheritedDatah">trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/ChangeLog        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -1,3 +1,41 @@
</span><ins>+2014-02-09  Zan Dobersek  &lt;zdobersek@igalia.com&gt;
+
+        Manage ShadowData through std::unique_ptr
+        https://bugs.webkit.org/show_bug.cgi?id=128466
+
+        Reviewed by Andreas Kling.
+
+        Use std::unique_ptr instead of OwnPtr to manage ShadowData objects.
+
+        * css/SVGCSSStyleSelector.cpp:
+        (WebCore::StyleResolver::applySVGProperty):
+        * css/StyleResolver.cpp:
+        (WebCore::StyleResolver::applyProperty):
+        * page/animation/CSSPropertyAnimation.cpp:
+        (WebCore::blendFunc):
+        (WebCore::PropertyWrapperShadow::PropertyWrapperShadow):
+        (WebCore::PropertyWrapperShadow::blendSimpleOrMatchedShadowLists):
+        (WebCore::PropertyWrapperShadow::blendMismatchedShadowLists):
+        * rendering/style/RenderStyle.cpp:
+        (WebCore::RenderStyle::setTextShadow):
+        (WebCore::RenderStyle::setBoxShadow):
+        * rendering/style/RenderStyle.h:
+        * rendering/style/SVGRenderStyle.h:
+        (WebCore::SVGRenderStyle::setShadow):
+        * rendering/style/SVGRenderStyleDefs.cpp:
+        (WebCore::StyleShadowSVGData::StyleShadowSVGData):
+        * rendering/style/SVGRenderStyleDefs.h:
+        * rendering/style/ShadowData.cpp:
+        (WebCore::ShadowData::ShadowData):
+        * rendering/style/ShadowData.h:
+        (WebCore::ShadowData::setNext):
+        * rendering/style/StyleRareInheritedData.cpp:
+        (WebCore::StyleRareInheritedData::StyleRareInheritedData):
+        * rendering/style/StyleRareInheritedData.h:
+        * rendering/style/StyleRareNonInheritedData.cpp:
+        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
+        * rendering/style/StyleRareNonInheritedData.h:
+
</ins><span class="cx"> 2014-02-09  Carlos Garnacho  &lt;carlosg@gnome.org&gt;
</span><span class="cx"> 
</span><span class="cx">         [GTK] Add touch-events related code to build
</span></span></pre></div>
<a id="trunkSourceWebCorecssSVGCSSStyleSelectorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/SVGCSSStyleSelector.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/SVGCSSStyleSelector.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/css/SVGCSSStyleSelector.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -548,7 +548,7 @@
</span><span class="cx">             break;
</span><span class="cx">         case CSSPropertyWebkitSvgShadow: {
</span><span class="cx">             if (isInherit)
</span><del>-                return svgStyle.setShadow(adoptPtr(state.parentStyle()-&gt;svgStyle().shadow() ? new ShadowData(*state.parentStyle()-&gt;svgStyle().shadow()) : 0));
</del><ins>+                return svgStyle.setShadow(state.parentStyle()-&gt;svgStyle().shadow() ? std::make_unique&lt;ShadowData&gt;(*state.parentStyle()-&gt;svgStyle().shadow()) : nullptr);
</ins><span class="cx">             if (isInitial || primitiveValue) // initial | none
</span><span class="cx">                 return svgStyle.setShadow(nullptr);
</span><span class="cx"> 
</span><span class="lines">@@ -574,8 +574,8 @@
</span><span class="cx">             ASSERT(!item-&gt;spread);
</span><span class="cx">             ASSERT(!item-&gt;style);
</span><span class="cx"> 
</span><del>-            OwnPtr&lt;ShadowData&gt; shadowData = adoptPtr(new ShadowData(location, blur, 0, Normal, false, color.isValid() ? color : Color::transparent));
-            svgStyle.setShadow(shadowData.release());
</del><ins>+            auto shadowData = std::make_unique&lt;ShadowData&gt;(location, blur, 0, Normal, false, color.isValid() ? color : Color::transparent);
+            svgStyle.setShadow(std::move(shadowData));
</ins><span class="cx">             return;
</span><span class="cx">         }
</span><span class="cx">         case CSSPropertyVectorEffect: {
</span></span></pre></div>
<a id="trunkSourceWebCorecssStyleResolvercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/StyleResolver.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/StyleResolver.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/css/StyleResolver.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -2307,8 +2307,8 @@
</span><span class="cx">     case CSSPropertyWebkitBoxShadow: {
</span><span class="cx">         if (isInherit) {
</span><span class="cx">             if (id == CSSPropertyTextShadow)
</span><del>-                return state.style()-&gt;setTextShadow(state.parentStyle()-&gt;textShadow() ? adoptPtr(new ShadowData(*state.parentStyle()-&gt;textShadow())) : nullptr);
-            return state.style()-&gt;setBoxShadow(state.parentStyle()-&gt;boxShadow() ? adoptPtr(new ShadowData(*state.parentStyle()-&gt;boxShadow())) : nullptr);
</del><ins>+                return state.style()-&gt;setTextShadow(state.parentStyle()-&gt;textShadow() ? std::make_unique&lt;ShadowData&gt;(*state.parentStyle()-&gt;textShadow()) : nullptr);
+            return state.style()-&gt;setBoxShadow(state.parentStyle()-&gt;boxShadow() ? std::make_unique&lt;ShadowData&gt;(*state.parentStyle()-&gt;boxShadow()) : nullptr);
</ins><span class="cx">         }
</span><span class="cx">         if (isInitial || primitiveValue) // initial | none
</span><span class="cx">             return id == CSSPropertyTextShadow ? state.style()-&gt;setTextShadow(nullptr) : state.style()-&gt;setBoxShadow(nullptr);
</span><span class="lines">@@ -2340,11 +2340,11 @@
</span><span class="cx">             else if (state.style())
</span><span class="cx">                 color = state.style()-&gt;color();
</span><span class="cx"> 
</span><del>-            OwnPtr&lt;ShadowData&gt; shadowData = adoptPtr(new ShadowData(IntPoint(x, y), blur, spread, shadowStyle, id == CSSPropertyWebkitBoxShadow, color.isValid() ? color : Color::transparent));
</del><ins>+            auto shadowData = std::make_unique&lt;ShadowData&gt;(IntPoint(x, y), blur, spread, shadowStyle, id == CSSPropertyWebkitBoxShadow, color.isValid() ? color : Color::transparent);
</ins><span class="cx">             if (id == CSSPropertyTextShadow)
</span><del>-                state.style()-&gt;setTextShadow(shadowData.release(), i.index()); // add to the list if this is not the first entry
</del><ins>+                state.style()-&gt;setTextShadow(std::move(shadowData), i.index()); // add to the list if this is not the first entry
</ins><span class="cx">             else
</span><del>-                state.style()-&gt;setBoxShadow(shadowData.release(), i.index()); // add to the list if this is not the first entry
</del><ins>+                state.style()-&gt;setBoxShadow(std::move(shadowData), i.index()); // add to the list if this is not the first entry
</ins><span class="cx">         }
</span><span class="cx">         return;
</span><span class="cx">     }
</span></span></pre></div>
<a id="trunkSourceWebCorepageanimationCSSPropertyAnimationcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/animation/CSSPropertyAnimation.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/animation/CSSPropertyAnimation.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/page/animation/CSSPropertyAnimation.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -99,18 +99,18 @@
</span><span class="cx">     return result &gt; 0 ? Normal : Inset;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static inline PassOwnPtr&lt;ShadowData&gt; blendFunc(const AnimationBase* anim, const ShadowData* from, const ShadowData* to, double progress)
</del><ins>+static inline std::unique_ptr&lt;ShadowData&gt; blendFunc(const AnimationBase* anim, const ShadowData* from, const ShadowData* to, double progress)
</ins><span class="cx"> {
</span><span class="cx">     ASSERT(from &amp;&amp; to);
</span><span class="cx">     if (from-&gt;style() != to-&gt;style())
</span><del>-        return adoptPtr(new ShadowData(*to));
</del><ins>+        return std::make_unique&lt;ShadowData&gt;(*to);
</ins><span class="cx"> 
</span><del>-    return adoptPtr(new ShadowData(blend(from-&gt;location(), to-&gt;location(), progress),
-                                   blend(from-&gt;radius(), to-&gt;radius(), progress),
-                                   blend(from-&gt;spread(), to-&gt;spread(), progress),
-                                   blendFunc(anim, from-&gt;style(), to-&gt;style(), progress),
-                                   from-&gt;isWebkitBoxShadow(),
-                                   blend(from-&gt;color(), to-&gt;color(), progress)));
</del><ins>+    return std::make_unique&lt;ShadowData&gt;(blend(from-&gt;location(), to-&gt;location(), progress),
+        blend(from-&gt;radius(), to-&gt;radius(), progress),
+        blend(from-&gt;spread(), to-&gt;spread(), progress),
+        blendFunc(anim, from-&gt;style(), to-&gt;style(), progress),
+        from-&gt;isWebkitBoxShadow(),
+        blend(from-&gt;color(), to-&gt;color(), progress));
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> static inline TransformOperations blendFunc(const AnimationBase* anim, const TransformOperations&amp; from, const TransformOperations&amp; to, double progress)
</span><span class="lines">@@ -601,7 +601,7 @@
</span><span class="cx"> 
</span><span class="cx"> class PropertyWrapperShadow : public AnimationPropertyWrapperBase {
</span><span class="cx"> public:
</span><del>-    PropertyWrapperShadow(CSSPropertyID prop, const ShadowData* (RenderStyle::*getter)() const, void (RenderStyle::*setter)(PassOwnPtr&lt;ShadowData&gt;, bool))
</del><ins>+    PropertyWrapperShadow(CSSPropertyID prop, const ShadowData* (RenderStyle::*getter)() const, void (RenderStyle::*setter)(std::unique_ptr&lt;ShadowData&gt;, bool))
</ins><span class="cx">         : AnimationPropertyWrapperBase(prop)
</span><span class="cx">         , m_getter(getter)
</span><span class="cx">         , m_setter(setter)
</span><span class="lines">@@ -649,22 +649,22 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx"> private:
</span><del>-    PassOwnPtr&lt;ShadowData&gt; blendSimpleOrMatchedShadowLists(const AnimationBase* anim, double progress, const ShadowData* shadowA, const ShadowData* shadowB) const
</del><ins>+    std::unique_ptr&lt;ShadowData&gt; blendSimpleOrMatchedShadowLists(const AnimationBase* anim, double progress, const ShadowData* shadowA, const ShadowData* shadowB) const
</ins><span class="cx">     {
</span><del>-        OwnPtr&lt;ShadowData&gt; newShadowData;
</del><ins>+        std::unique_ptr&lt;ShadowData&gt; newShadowData;
</ins><span class="cx">         ShadowData* lastShadow = 0;
</span><span class="cx"> 
</span><span class="cx">         while (shadowA || shadowB) {
</span><span class="cx">             const ShadowData* srcShadow = shadowForBlending(shadowA, shadowB);
</span><span class="cx">             const ShadowData* dstShadow = shadowForBlending(shadowB, shadowA);
</span><span class="cx"> 
</span><del>-            OwnPtr&lt;ShadowData&gt; blendedShadow = blendFunc(anim, srcShadow, dstShadow, progress);
</del><ins>+            std::unique_ptr&lt;ShadowData&gt; blendedShadow = blendFunc(anim, srcShadow, dstShadow, progress);
</ins><span class="cx">             ShadowData* blendedShadowPtr = blendedShadow.get();
</span><span class="cx"> 
</span><span class="cx">             if (!lastShadow)
</span><del>-                newShadowData = blendedShadow.release();
</del><ins>+                newShadowData = std::move(blendedShadow);
</ins><span class="cx">             else
</span><del>-                lastShadow-&gt;setNext(blendedShadow.release());
</del><ins>+                lastShadow-&gt;setNext(std::move(blendedShadow));
</ins><span class="cx"> 
</span><span class="cx">             lastShadow = blendedShadowPtr;
</span><span class="cx"> 
</span><span class="lines">@@ -672,10 +672,10 @@
</span><span class="cx">             shadowB = shadowB ? shadowB-&gt;next() : 0;
</span><span class="cx">         }
</span><span class="cx"> 
</span><del>-        return newShadowData.release();
</del><ins>+        return newShadowData;
</ins><span class="cx">     }
</span><span class="cx"> 
</span><del>-    PassOwnPtr&lt;ShadowData&gt; blendMismatchedShadowLists(const AnimationBase* anim, double progress, const ShadowData* shadowA, const ShadowData* shadowB, int fromLength, int toLength) const
</del><ins>+    std::unique_ptr&lt;ShadowData&gt; blendMismatchedShadowLists(const AnimationBase* anim, double progress, const ShadowData* shadowA, const ShadowData* shadowB, int fromLength, int toLength) const
</ins><span class="cx">     {
</span><span class="cx">         // The shadows in ShadowData are stored in reverse order, so when animating mismatched lists,
</span><span class="cx">         // reverse them and match from the end.
</span><span class="lines">@@ -691,7 +691,7 @@
</span><span class="cx">             shadowB = shadowB-&gt;next();
</span><span class="cx">         }
</span><span class="cx"> 
</span><del>-        OwnPtr&lt;ShadowData&gt; newShadowData;
</del><ins>+        std::unique_ptr&lt;ShadowData&gt; newShadowData;
</ins><span class="cx"> 
</span><span class="cx">         int maxLength = std::max(fromLength, toLength);
</span><span class="cx">         for (int i = 0; i &lt; maxLength; ++i) {
</span><span class="lines">@@ -701,17 +701,17 @@
</span><span class="cx">             const ShadowData* srcShadow = shadowForBlending(fromShadow, toShadow);
</span><span class="cx">             const ShadowData* dstShadow = shadowForBlending(toShadow, fromShadow);
</span><span class="cx"> 
</span><del>-            OwnPtr&lt;ShadowData&gt; blendedShadow = blendFunc(anim, srcShadow, dstShadow, progress);
</del><ins>+            std::unique_ptr&lt;ShadowData&gt; blendedShadow = blendFunc(anim, srcShadow, dstShadow, progress);
</ins><span class="cx">             // Insert at the start of the list to preserve the order.
</span><del>-            blendedShadow-&gt;setNext(newShadowData.release());
-            newShadowData = blendedShadow.release();
</del><ins>+            blendedShadow-&gt;setNext(std::move(newShadowData));
+            newShadowData = std::move(blendedShadow);
</ins><span class="cx">         }
</span><span class="cx"> 
</span><del>-        return newShadowData.release();
</del><ins>+        return newShadowData;
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     const ShadowData* (RenderStyle::*m_getter)() const;
</span><del>-    void (RenderStyle::*m_setter)(PassOwnPtr&lt;ShadowData&gt;, bool);
</del><ins>+    void (RenderStyle::*m_setter)(std::unique_ptr&lt;ShadowData&gt;, bool);
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> class PropertyWrapperMaybeInvalidColor : public AnimationPropertyWrapperBase {
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleRenderStylecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/RenderStyle.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/RenderStyle.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/RenderStyle.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -1022,30 +1022,30 @@
</span><span class="cx">     setTransformOriginY(Length(0, Fixed));
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void RenderStyle::setTextShadow(PassOwnPtr&lt;ShadowData&gt; shadowData, bool add)
</del><ins>+void RenderStyle::setTextShadow(std::unique_ptr&lt;ShadowData&gt; shadowData, bool add)
</ins><span class="cx"> {
</span><span class="cx">     ASSERT(!shadowData || (!shadowData-&gt;spread() &amp;&amp; shadowData-&gt;style() == Normal));
</span><span class="cx"> 
</span><span class="cx">     StyleRareInheritedData* rareData = rareInheritedData.access();
</span><span class="cx">     if (!add) {
</span><del>-        rareData-&gt;textShadow = shadowData;
</del><ins>+        rareData-&gt;textShadow = std::move(shadowData);
</ins><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    shadowData-&gt;setNext(rareData-&gt;textShadow.release());
-    rareData-&gt;textShadow = shadowData;
</del><ins>+    shadowData-&gt;setNext(std::move(rareData-&gt;textShadow));
+    rareData-&gt;textShadow = std::move(shadowData);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-void RenderStyle::setBoxShadow(PassOwnPtr&lt;ShadowData&gt; shadowData, bool add)
</del><ins>+void RenderStyle::setBoxShadow(std::unique_ptr&lt;ShadowData&gt; shadowData, bool add)
</ins><span class="cx"> {
</span><span class="cx">     StyleRareNonInheritedData* rareData = rareNonInheritedData.access();
</span><span class="cx">     if (!add) {
</span><del>-        rareData-&gt;m_boxShadow = shadowData;
</del><ins>+        rareData-&gt;m_boxShadow = std::move(shadowData);
</ins><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    shadowData-&gt;setNext(rareData-&gt;m_boxShadow.release());
-    rareData-&gt;m_boxShadow = shadowData;
</del><ins>+    shadowData-&gt;setNext(std::move(rareData-&gt;m_boxShadow));
+    rareData-&gt;m_boxShadow = std::move(shadowData);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> static RoundedRect::Radii calcRadiiFor(const BorderData&amp; border, const LayoutSize&amp; size, RenderView* renderView)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleRenderStyleh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/RenderStyle.h (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/RenderStyle.h        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/RenderStyle.h        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -1270,7 +1270,7 @@
</span><span class="cx"> 
</span><span class="cx">     // CSS3 Setters
</span><span class="cx">     void setOutlineOffset(int v) { SET_VAR(m_background, m_outline.m_offset, v); }
</span><del>-    void setTextShadow(PassOwnPtr&lt;ShadowData&gt;, bool add = false);
</del><ins>+    void setTextShadow(std::unique_ptr&lt;ShadowData&gt;, bool add = false);
</ins><span class="cx">     void setTextStrokeColor(const Color&amp; c) { SET_VAR(rareInheritedData, textStrokeColor, c); }
</span><span class="cx">     void setTextStrokeWidth(float w) { SET_VAR(rareInheritedData, textStrokeWidth, w); }
</span><span class="cx">     void setTextFillColor(const Color&amp; c) { SET_VAR(rareInheritedData, textFillColor, c); }
</span><span class="lines">@@ -1289,7 +1289,7 @@
</span><span class="cx">     void setBoxOrdinalGroup(unsigned int og) { SET_VAR(rareNonInheritedData.access()-&gt;m_deprecatedFlexibleBox, ordinal_group, og); }
</span><span class="cx">     void setBoxOrient(EBoxOrient o) { SET_VAR(rareNonInheritedData.access()-&gt;m_deprecatedFlexibleBox, orient, o); }
</span><span class="cx">     void setBoxPack(EBoxPack p) { SET_VAR(rareNonInheritedData.access()-&gt;m_deprecatedFlexibleBox, pack, p); }
</span><del>-    void setBoxShadow(PassOwnPtr&lt;ShadowData&gt;, bool add = false);
</del><ins>+    void setBoxShadow(std::unique_ptr&lt;ShadowData&gt;, bool add = false);
</ins><span class="cx">     void setBoxReflect(PassRefPtr&lt;StyleReflection&gt; reflect) { if (rareNonInheritedData-&gt;m_boxReflect != reflect) rareNonInheritedData.access()-&gt;m_boxReflect = reflect; }
</span><span class="cx">     void setBoxSizing(EBoxSizing s) { SET_VAR(m_box, m_boxSizing, s); }
</span><span class="cx">     void setFlexGrow(float f) { SET_VAR(rareNonInheritedData.access()-&gt;m_flexibleBox, m_flexGrow, f); }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleSVGRenderStyleh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/SVGRenderStyle.h (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/SVGRenderStyle.h        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/SVGRenderStyle.h        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -262,7 +262,7 @@
</span><span class="cx">             misc.access()-&gt;baselineShiftValue = obj;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    void setShadow(PassOwnPtr&lt;ShadowData&gt; obj) { shadowSVG.access()-&gt;shadow = obj; }
</del><ins>+    void setShadow(std::unique_ptr&lt;ShadowData&gt; obj) { shadowSVG.access()-&gt;shadow = std::move(obj); }
</ins><span class="cx"> 
</span><span class="cx">     // Setters for non-inherited resources
</span><span class="cx">     void setClipperResource(const String&amp; obj)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleSVGRenderStyleDefscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -204,7 +204,7 @@
</span><span class="cx"> 
</span><span class="cx"> inline StyleShadowSVGData::StyleShadowSVGData(const StyleShadowSVGData&amp; other)
</span><span class="cx">     : RefCounted&lt;StyleShadowSVGData&gt;()
</span><del>-    , shadow(other.shadow ? adoptPtr(new ShadowData(*other.shadow)) : nullptr)
</del><ins>+    , shadow(other.shadow ? std::make_unique&lt;ShadowData&gt;(*other.shadow) : nullptr)
</ins><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleSVGRenderStyleDefsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.h (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.h        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/SVGRenderStyleDefs.h        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -31,8 +31,6 @@
</span><span class="cx"> #include &quot;SVGLength.h&quot;
</span><span class="cx"> #include &quot;SVGPaint.h&quot;
</span><span class="cx"> #include &quot;ShadowData.h&quot;
</span><del>-#include &lt;wtf/OwnPtr.h&gt;
-#include &lt;wtf/PassOwnPtr.h&gt;
</del><span class="cx"> #include &lt;wtf/RefCounted.h&gt;
</span><span class="cx"> #include &lt;wtf/RefPtr.h&gt;
</span><span class="cx"> 
</span><span class="lines">@@ -224,7 +222,7 @@
</span><span class="cx">             return !(*this == other);
</span><span class="cx">         }
</span><span class="cx"> 
</span><del>-        OwnPtr&lt;ShadowData&gt; shadow;
</del><ins>+        std::unique_ptr&lt;ShadowData&gt; shadow;
</ins><span class="cx"> 
</span><span class="cx">     private:
</span><span class="cx">         StyleShadowSVGData();
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleShadowDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/ShadowData.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/ShadowData.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/ShadowData.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -33,7 +33,7 @@
</span><span class="cx">     , m_color(o.m_color)
</span><span class="cx">     , m_style(o.m_style)
</span><span class="cx">     , m_isWebkitBoxShadow(o.m_isWebkitBoxShadow)
</span><del>-    , m_next(o.m_next ? adoptPtr(new ShadowData(*o.m_next)) : nullptr)
</del><ins>+    , m_next(o.m_next ? std::make_unique&lt;ShadowData&gt;(*o.m_next) : nullptr)
</ins><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleShadowDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/ShadowData.h (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/ShadowData.h        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/ShadowData.h        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -28,8 +28,6 @@
</span><span class="cx"> #include &quot;Color.h&quot;
</span><span class="cx"> #include &quot;FloatRect.h&quot;
</span><span class="cx"> #include &quot;LayoutRect.h&quot;
</span><del>-#include &lt;wtf/OwnPtr.h&gt;
-#include &lt;wtf/PassOwnPtr.h&gt;
</del><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><span class="lines">@@ -84,7 +82,7 @@
</span><span class="cx">     bool isWebkitBoxShadow() const { return m_isWebkitBoxShadow; }
</span><span class="cx"> 
</span><span class="cx">     const ShadowData* next() const { return m_next.get(); }
</span><del>-    void setNext(PassOwnPtr&lt;ShadowData&gt; shadow) { m_next = shadow; }
</del><ins>+    void setNext(std::unique_ptr&lt;ShadowData&gt; shadow) { m_next = std::move(shadow); }
</ins><span class="cx"> 
</span><span class="cx">     void adjustRectForShadow(LayoutRect&amp;, int additionalOutlineSize = 0) const;
</span><span class="cx">     void adjustRectForShadow(FloatRect&amp;, int additionalOutlineSize = 0) const;
</span><span class="lines">@@ -96,7 +94,7 @@
</span><span class="cx">     Color m_color;
</span><span class="cx">     ShadowStyle m_style;
</span><span class="cx">     bool m_isWebkitBoxShadow;
</span><del>-    OwnPtr&lt;ShadowData&gt; m_next;
</del><ins>+    std::unique_ptr&lt;ShadowData&gt; m_next;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleStyleRareInheritedDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/StyleRareInheritedData.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/StyleRareInheritedData.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/StyleRareInheritedData.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -146,7 +146,7 @@
</span><span class="cx">     , visitedLinkTextStrokeColor(o.visitedLinkTextStrokeColor)
</span><span class="cx">     , visitedLinkTextFillColor(o.visitedLinkTextFillColor)
</span><span class="cx">     , visitedLinkTextEmphasisColor(o.visitedLinkTextEmphasisColor)
</span><del>-    , textShadow(o.textShadow ? adoptPtr(new ShadowData(*o.textShadow)) : nullptr)
</del><ins>+    , textShadow(o.textShadow ? std::make_unique&lt;ShadowData&gt;(*o.textShadow) : nullptr)
</ins><span class="cx">     , cursorData(o.cursorData)
</span><span class="cx">     , indent(o.indent)
</span><span class="cx">     , m_effectiveZoom(o.m_effectiveZoom)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleStyleRareInheritedDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/StyleRareInheritedData.h (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/StyleRareInheritedData.h        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/StyleRareInheritedData.h        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -69,7 +69,7 @@
</span><span class="cx">     Color visitedLinkTextFillColor;
</span><span class="cx">     Color visitedLinkTextEmphasisColor;    
</span><span class="cx"> 
</span><del>-    OwnPtr&lt;ShadowData&gt; textShadow; // Our text shadow information for shadowed text drawing.
</del><ins>+    std::unique_ptr&lt;ShadowData&gt; textShadow; // Our text shadow information for shadowed text drawing.
</ins><span class="cx">     
</span><span class="cx">     RefPtr&lt;CursorList&gt; cursorData;
</span><span class="cx">     Length indent;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleStyleRareNonInheritedDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -119,7 +119,7 @@
</span><span class="cx">     , m_gridItem(o.m_gridItem)
</span><span class="cx">     , m_content(o.m_content ? o.m_content-&gt;clone() : nullptr)
</span><span class="cx">     , m_counterDirectives(o.m_counterDirectives ? clone(*o.m_counterDirectives) : nullptr)
</span><del>-    , m_boxShadow(o.m_boxShadow ? adoptPtr(new ShadowData(*o.m_boxShadow)) : nullptr)
</del><ins>+    , m_boxShadow(o.m_boxShadow ? std::make_unique&lt;ShadowData&gt;(*o.m_boxShadow) : nullptr)
</ins><span class="cx">     , m_boxReflect(o.m_boxReflect)
</span><span class="cx">     , m_animations(o.m_animations ? adoptPtr(new AnimationList(*o.m_animations)) : nullptr)
</span><span class="cx">     , m_transitions(o.m_transitions ? adoptPtr(new AnimationList(*o.m_transitions)) : nullptr)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleStyleRareNonInheritedDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.h (163750 => 163751)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.h        2014-02-09 11:39:30 UTC (rev 163750)
+++ trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.h        2014-02-09 12:11:01 UTC (rev 163751)
</span><span class="lines">@@ -124,7 +124,7 @@
</span><span class="cx">     OwnPtr&lt;CounterDirectiveMap&gt; m_counterDirectives;
</span><span class="cx">     String m_altText;
</span><span class="cx"> 
</span><del>-    OwnPtr&lt;ShadowData&gt; m_boxShadow;  // For box-shadow decorations.
</del><ins>+    std::unique_ptr&lt;ShadowData&gt; m_boxShadow; // For box-shadow decorations.
</ins><span class="cx">     
</span><span class="cx">     RefPtr&lt;StyleReflection&gt; m_boxReflect;
</span><span class="cx"> 
</span></span></pre>
</div>
</div>

</body>
</html>