<!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>[165055] trunk/Source</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/165055">165055</a></dd>
<dt>Author</dt> <dd>zalan@apple.com</dd>
<dt>Date</dt> <dd>2014-03-04 09:06:50 -0800 (Tue, 04 Mar 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Subpixel rendering: Make GraphicsLayer::fillRect FloatRoundedRect based and cleanup dependencies.
https://bugs.webkit.org/show_bug.cgi?id=129557

Reviewed by Simon Fraser.

This is the preparation for snapping rounded rects to device pixel position. It enables
device pixel aware border-radius painting.

No change in functionality.

Source/WebCore:

* platform/efl/RenderThemeEfl.cpp:
(WebCore::RenderThemeEfl::paintMediaSliderThumb):
* platform/graphics/FloatRoundedRect.cpp:
(WebCore::FloatRoundedRect::FloatRoundedRect):
(WebCore::FloatRoundedRect::isRenderable):
* platform/graphics/FloatRoundedRect.h:
* platform/graphics/GraphicsContext.cpp:
(WebCore::GraphicsContext::clipRoundedRect):
(WebCore::GraphicsContext::clipOutRoundedRect):
(WebCore::GraphicsContext::fillRoundedRect):
(WebCore::GraphicsContext::fillRectWithRoundedHole):
* platform/graphics/GraphicsContext.h:
* platform/graphics/Path.cpp:
(WebCore::Path::addRoundedRect):
* platform/graphics/Path.h:
* platform/graphics/RoundedRect.cpp:
(WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
* platform/graphics/RoundedRect.h:
* platform/graphics/ShadowBlur.cpp:
(WebCore::ShadowBlur::drawRectShadow):
(WebCore::ShadowBlur::drawInsetShadow):
(WebCore::ShadowBlur::drawRectShadowWithoutTiling):
(WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
(WebCore::ShadowBlur::drawInsetShadowWithTiling):
(WebCore::ShadowBlur::drawRectShadowWithTiling):
* platform/graphics/ShadowBlur.h:
* platform/graphics/cairo/GraphicsContextCairo.cpp:
(WebCore::GraphicsContext::fillRect):
(WebCore::GraphicsContext::platformFillRoundedRect):
(WebCore::GraphicsContext::fillRectWithRoundedHole):
* platform/graphics/cg/GraphicsContextCG.cpp:
(WebCore::GraphicsContext::fillRect):
(WebCore::GraphicsContext::platformFillRoundedRect):
(WebCore::GraphicsContext::fillRectWithRoundedHole):
* platform/graphics/wince/GraphicsContextWinCE.cpp:
(WebCore::GraphicsContext::fillRoundedRect):
* platform/gtk/RenderThemeGtk.cpp:
(WebCore::borderRadiiFromStyle):
(WebCore::RenderThemeGtk::paintMediaSliderTrack):
(WebCore::RenderThemeGtk::paintMediaSliderThumb):
(WebCore::RenderThemeGtk::paintMediaVolumeSliderTrack):
* platform/win/DragImageWin.cpp:
(WebCore::createDragImageForLink):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::paintBoxDecorations):
(WebCore::RenderBox::pushContentsClip):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::clipRoundedInnerRect):
(WebCore::RenderBoxModelObject::paintFillLayerExtended):
(WebCore::RenderBoxModelObject::paintBorder):
(WebCore::RenderBoxModelObject::drawBoxSideFromPath):
(WebCore::RenderBoxModelObject::clipBorderSideForComplexInnerPath):
(WebCore::RenderBoxModelObject::paintBoxShadow):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::clipToRect):
* rendering/RenderThemeIOS.mm:
(WebCore::RenderThemeIOS::paintRadioDecorations):
(WebCore::RenderThemeIOS::paintTextFieldDecorations):
(WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
(WebCore::RenderThemeIOS::paintSliderTrack):
(WebCore::RenderThemeIOS::paintProgressBar):
(WebCore::RenderThemeIOS::paintFileUploadIconDecorations):
* rendering/RenderThemeMac.mm:
(WebCore::RenderThemeMac::paintMenuListButtonGradients):
(WebCore::RenderThemeMac::paintSliderTrack):
* rendering/RenderThemeSafari.cpp:
(WebCore::RenderThemeSafari::paintMenuListButtonGradients):
(WebCore::RenderThemeSafari::paintSliderTrack):
* rendering/shapes/BoxShape.cpp:
(WebCore::BoxShape::buildDisplayPaths):
* rendering/style/BasicShapes.cpp:
(WebCore::BasicShapeInset::path):

Source/WebKit/win:

* FullscreenVideoController.cpp:
(HUDSlider::draw):
(FullscreenVideoController::draw):</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreplatformeflRenderThemeEflcpp">trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsFloatRoundedRectcpp">trunk/Source/WebCore/platform/graphics/FloatRoundedRect.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsFloatRoundedRecth">trunk/Source/WebCore/platform/graphics/FloatRoundedRect.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsGraphicsContextcpp">trunk/Source/WebCore/platform/graphics/GraphicsContext.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsGraphicsContexth">trunk/Source/WebCore/platform/graphics/GraphicsContext.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsPathcpp">trunk/Source/WebCore/platform/graphics/Path.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsPathh">trunk/Source/WebCore/platform/graphics/Path.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsRoundedRectcpp">trunk/Source/WebCore/platform/graphics/RoundedRect.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsRoundedRecth">trunk/Source/WebCore/platform/graphics/RoundedRect.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsShadowBlurcpp">trunk/Source/WebCore/platform/graphics/ShadowBlur.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsShadowBlurh">trunk/Source/WebCore/platform/graphics/ShadowBlur.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicscairoGraphicsContextCairocpp">trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextCairo.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicscgGraphicsContextCGcpp">trunk/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicswinceGraphicsContextWinCEcpp">trunk/Source/WebCore/platform/graphics/wince/GraphicsContextWinCE.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgtkRenderThemeGtkcpp">trunk/Source/WebCore/platform/gtk/RenderThemeGtk.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformwinDragImageWincpp">trunk/Source/WebCore/platform/win/DragImageWin.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderBoxcpp">trunk/Source/WebCore/rendering/RenderBox.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderBoxModelObjectcpp">trunk/Source/WebCore/rendering/RenderBoxModelObject.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderLayercpp">trunk/Source/WebCore/rendering/RenderLayer.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderThemeIOSmm">trunk/Source/WebCore/rendering/RenderThemeIOS.mm</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderThemeMacmm">trunk/Source/WebCore/rendering/RenderThemeMac.mm</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderThemeSafaricpp">trunk/Source/WebCore/rendering/RenderThemeSafari.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingshapesBoxShapecpp">trunk/Source/WebCore/rendering/shapes/BoxShape.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingstyleBasicShapescpp">trunk/Source/WebCore/rendering/style/BasicShapes.cpp</a></li>
<li><a href="#trunkSourceWebKitwinChangeLog">trunk/Source/WebKit/win/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitwinFullscreenVideoControllercpp">trunk/Source/WebKit/win/FullscreenVideoController.cpp</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/ChangeLog        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -1,3 +1,88 @@
</span><ins>+2014-03-04  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+        Subpixel rendering: Make GraphicsLayer::fillRect FloatRoundedRect based and cleanup dependencies.
+        https://bugs.webkit.org/show_bug.cgi?id=129557
+
+        Reviewed by Simon Fraser.
+
+        This is the preparation for snapping rounded rects to device pixel position. It enables
+        device pixel aware border-radius painting.
+
+        No change in functionality.
+
+        * platform/efl/RenderThemeEfl.cpp:
+        (WebCore::RenderThemeEfl::paintMediaSliderThumb):
+        * platform/graphics/FloatRoundedRect.cpp:
+        (WebCore::FloatRoundedRect::FloatRoundedRect):
+        (WebCore::FloatRoundedRect::isRenderable):
+        * platform/graphics/FloatRoundedRect.h:
+        * platform/graphics/GraphicsContext.cpp:
+        (WebCore::GraphicsContext::clipRoundedRect):
+        (WebCore::GraphicsContext::clipOutRoundedRect):
+        (WebCore::GraphicsContext::fillRoundedRect):
+        (WebCore::GraphicsContext::fillRectWithRoundedHole):
+        * platform/graphics/GraphicsContext.h:
+        * platform/graphics/Path.cpp:
+        (WebCore::Path::addRoundedRect):
+        * platform/graphics/Path.h:
+        * platform/graphics/RoundedRect.cpp:
+        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
+        * platform/graphics/RoundedRect.h:
+        * platform/graphics/ShadowBlur.cpp:
+        (WebCore::ShadowBlur::drawRectShadow):
+        (WebCore::ShadowBlur::drawInsetShadow):
+        (WebCore::ShadowBlur::drawRectShadowWithoutTiling):
+        (WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
+        (WebCore::ShadowBlur::drawInsetShadowWithTiling):
+        (WebCore::ShadowBlur::drawRectShadowWithTiling):
+        * platform/graphics/ShadowBlur.h:
+        * platform/graphics/cairo/GraphicsContextCairo.cpp:
+        (WebCore::GraphicsContext::fillRect):
+        (WebCore::GraphicsContext::platformFillRoundedRect):
+        (WebCore::GraphicsContext::fillRectWithRoundedHole):
+        * platform/graphics/cg/GraphicsContextCG.cpp:
+        (WebCore::GraphicsContext::fillRect):
+        (WebCore::GraphicsContext::platformFillRoundedRect):
+        (WebCore::GraphicsContext::fillRectWithRoundedHole):
+        * platform/graphics/wince/GraphicsContextWinCE.cpp:
+        (WebCore::GraphicsContext::fillRoundedRect):
+        * platform/gtk/RenderThemeGtk.cpp:
+        (WebCore::borderRadiiFromStyle):
+        (WebCore::RenderThemeGtk::paintMediaSliderTrack):
+        (WebCore::RenderThemeGtk::paintMediaSliderThumb):
+        (WebCore::RenderThemeGtk::paintMediaVolumeSliderTrack):
+        * platform/win/DragImageWin.cpp:
+        (WebCore::createDragImageForLink):
+        * rendering/RenderBox.cpp:
+        (WebCore::RenderBox::paintBoxDecorations):
+        (WebCore::RenderBox::pushContentsClip):
+        * rendering/RenderBoxModelObject.cpp:
+        (WebCore::RenderBoxModelObject::clipRoundedInnerRect):
+        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
+        (WebCore::RenderBoxModelObject::paintBorder):
+        (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
+        (WebCore::RenderBoxModelObject::clipBorderSideForComplexInnerPath):
+        (WebCore::RenderBoxModelObject::paintBoxShadow):
+        * rendering/RenderLayer.cpp:
+        (WebCore::RenderLayer::clipToRect):
+        * rendering/RenderThemeIOS.mm:
+        (WebCore::RenderThemeIOS::paintRadioDecorations):
+        (WebCore::RenderThemeIOS::paintTextFieldDecorations):
+        (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
+        (WebCore::RenderThemeIOS::paintSliderTrack):
+        (WebCore::RenderThemeIOS::paintProgressBar):
+        (WebCore::RenderThemeIOS::paintFileUploadIconDecorations):
+        * rendering/RenderThemeMac.mm:
+        (WebCore::RenderThemeMac::paintMenuListButtonGradients):
+        (WebCore::RenderThemeMac::paintSliderTrack):
+        * rendering/RenderThemeSafari.cpp:
+        (WebCore::RenderThemeSafari::paintMenuListButtonGradients):
+        (WebCore::RenderThemeSafari::paintSliderTrack):
+        * rendering/shapes/BoxShape.cpp:
+        (WebCore::BoxShape::buildDisplayPaths):
+        * rendering/style/BasicShapes.cpp:
+        (WebCore::BasicShapeInset::path):
+
</ins><span class="cx"> 2014-03-04  Andreas Kling  &lt;akling@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Micro-optimize Strings in JS bindings.
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformeflRenderThemeEflcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -30,6 +30,7 @@
</span><span class="cx"> #include &quot;CSSValueKeywords.h&quot;
</span><span class="cx"> #include &quot;CairoUtilitiesEfl.h&quot;
</span><span class="cx"> #include &quot;ExceptionCodePlaceholder.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;FontDescription.h&quot;
</span><span class="cx"> #include &quot;GraphicsContext.h&quot;
</span><span class="cx"> #include &quot;HTMLInputElement.h&quot;
</span><span class="lines">@@ -1242,7 +1243,7 @@
</span><span class="cx"> bool RenderThemeEfl::paintMediaSliderThumb(RenderObject*, const PaintInfo&amp; info, const IntRect&amp; rect)
</span><span class="cx"> {
</span><span class="cx">     IntSize thumbRect(3, 3);
</span><del>-    info.context-&gt;fillRoundedRect(rect, thumbRect, thumbRect, thumbRect, thumbRect, m_sliderThumbColor, ColorSpaceDeviceRGB);
</del><ins>+    info.context-&gt;fillRoundedRect(FloatRoundedRect(rect, thumbRect, thumbRect, thumbRect, thumbRect), m_sliderThumbColor, ColorSpaceDeviceRGB);
</ins><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsFloatRoundedRectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/FloatRoundedRect.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/FloatRoundedRect.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/FloatRoundedRect.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -34,6 +34,12 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><ins>+FloatRoundedRect::FloatRoundedRect(const RoundedRect&amp; rect)
+    : m_rect(rect.rect())
+    , m_radii(rect.radii())
+{
+}
+
</ins><span class="cx"> FloatRoundedRect::FloatRoundedRect(float x, float y, float width, float height)
</span><span class="cx">     : m_rect(x, y, width, height)
</span><span class="cx"> {
</span><span class="lines">@@ -137,4 +143,12 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool FloatRoundedRect::isRenderable() const
+{
+    return m_radii.topLeft().width() + m_radii.topRight().width() &lt;= m_rect.width()
+        &amp;&amp; m_radii.bottomLeft().width() + m_radii.bottomRight().width() &lt;= m_rect.width()
+        &amp;&amp; m_radii.topLeft().height() + m_radii.bottomLeft().height() &lt;= m_rect.height()
+        &amp;&amp; m_radii.topRight().height() + m_radii.bottomRight().height() &lt;= m_rect.height();
+}
+
</ins><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsFloatRoundedRecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/FloatRoundedRect.h (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/FloatRoundedRect.h        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/FloatRoundedRect.h        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -82,6 +82,7 @@
</span><span class="cx">     };
</span><span class="cx"> 
</span><span class="cx">     explicit FloatRoundedRect(const FloatRect&amp;, const Radii&amp; = Radii());
</span><ins>+    explicit FloatRoundedRect(const RoundedRect&amp;);
</ins><span class="cx">     FloatRoundedRect(float x, float y, float width, float height);
</span><span class="cx">     FloatRoundedRect(const FloatRect&amp;, const FloatSize&amp; topLeft, const FloatSize&amp; topRight, const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight);
</span><span class="cx"> 
</span><span class="lines">@@ -115,6 +116,7 @@
</span><span class="cx">         return FloatRect(m_rect.maxX() - m_radii.bottomRight().width(), m_rect.maxY() - m_radii.bottomRight().height(), m_radii.bottomRight().width(), m_radii.bottomRight().height());
</span><span class="cx">     }
</span><span class="cx"> 
</span><ins>+    bool isRenderable() const;
</ins><span class="cx">     bool xInterceptsAtY(float y, float&amp; minXIntercept, float&amp; maxXIntercept) const;
</span><span class="cx"> 
</span><span class="cx"> private:
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsGraphicsContextcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/GraphicsContext.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/GraphicsContext.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/GraphicsContext.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -28,6 +28,7 @@
</span><span class="cx"> 
</span><span class="cx"> #include &quot;BidiResolver.h&quot;
</span><span class="cx"> #include &quot;BitmapImage.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;Gradient.h&quot;
</span><span class="cx"> #include &quot;ImageBuffer.h&quot;
</span><span class="cx"> #include &quot;IntRect.h&quot;
</span><span class="lines">@@ -681,38 +682,21 @@
</span><span class="cx">     clip(FloatRect(rect));
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void GraphicsContext::clipRoundedRect(const RoundedRect&amp; rect)
</del><ins>+void GraphicsContext::clipRoundedRect(const FloatRoundedRect&amp; rect)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled())
</span><span class="cx">         return;
</span><span class="cx"> 
</span><del>-    if (!rect.isRounded()) {
-        clip(rect.rect());
-        return;
-    }
-
</del><span class="cx">     Path path;
</span><span class="cx">     path.addRoundedRect(rect);
</span><span class="cx">     clip(path);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-// FIXME: Consider writing this in terms of a specialized RoundedRect that uses FloatRect and FloatSize radii.
-void GraphicsContext::clipRoundedRect(const FloatRect&amp; rect, const FloatSize&amp; topLeft, const FloatSize&amp; topRight,
-    const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight)
</del><ins>+void GraphicsContext::clipOutRoundedRect(const FloatRoundedRect&amp; rect)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled())
</span><span class="cx">         return;
</span><span class="cx"> 
</span><del>-    Path path;
-    path.addRoundedRect(rect, topLeft, topRight, bottomLeft, bottomRight);
-    clip(path);
-}
-
-void GraphicsContext::clipOutRoundedRect(const RoundedRect&amp; rect)
-{
-    if (paintingDisabled())
-        return;
-
</del><span class="cx">     if (!rect.isRounded()) {
</span><span class="cx">         clipOut(rect.rect());
</span><span class="cx">         return;
</span><span class="lines">@@ -769,18 +753,18 @@
</span><span class="cx">     setCompositeOperation(previousOperator);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void GraphicsContext::fillRoundedRect(const RoundedRect&amp; rect, const Color&amp; color, ColorSpace colorSpace, BlendMode blendMode)
</del><ins>+void GraphicsContext::fillRoundedRect(const FloatRoundedRect&amp; rect, const Color&amp; color, ColorSpace colorSpace, BlendMode blendMode)
</ins><span class="cx"> {
</span><span class="cx">     if (rect.isRounded()) {
</span><span class="cx">         setCompositeOperation(compositeOperation(), blendMode);
</span><del>-        fillRoundedRect(rect.rect(), rect.radii().topLeft(), rect.radii().topRight(), rect.radii().bottomLeft(), rect.radii().bottomRight(), color, colorSpace);
</del><ins>+        platformFillRoundedRect(rect, color, colorSpace);
</ins><span class="cx">         setCompositeOperation(compositeOperation());
</span><span class="cx">     } else
</span><span class="cx">         fillRect(rect.rect(), color, colorSpace, compositeOperation(), blendMode);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if !USE(CG) &amp;&amp; !USE(CAIRO)
</span><del>-void GraphicsContext::fillRectWithRoundedHole(const IntRect&amp; rect, const RoundedRect&amp; roundedHoleRect, const Color&amp; color, ColorSpace colorSpace)
</del><ins>+void GraphicsContext::fillRectWithRoundedHole(const IntRect&amp; rect, const FloatRoundedRect&amp; roundedHoleRect, const Color&amp; color, ColorSpace colorSpace)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled())
</span><span class="cx">         return;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsGraphicsContexth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/GraphicsContext.h (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/GraphicsContext.h        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/GraphicsContext.h        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -75,6 +75,7 @@
</span><span class="cx"> 
</span><span class="cx">     class AffineTransform;
</span><span class="cx">     class DrawingBuffer;
</span><ins>+    class FloatRoundedRect;
</ins><span class="cx">     class Gradient;
</span><span class="cx">     class GraphicsContextPlatformPrivate;
</span><span class="cx">     class ImageBuffer;
</span><span class="lines">@@ -294,9 +295,8 @@
</span><span class="cx">         void fillRect(const FloatRect&amp;, const Color&amp;, ColorSpace);
</span><span class="cx">         void fillRect(const FloatRect&amp;, Gradient&amp;);
</span><span class="cx">         void fillRect(const FloatRect&amp;, const Color&amp;, ColorSpace, CompositeOperator, BlendMode = BlendModeNormal);
</span><del>-        void fillRoundedRect(const FloatRect&amp;, const FloatSize&amp; topLeft, const FloatSize&amp; topRight, const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight, const Color&amp;, ColorSpace);
-        void fillRoundedRect(const RoundedRect&amp;, const Color&amp;, ColorSpace, BlendMode = BlendModeNormal);
-        void fillRectWithRoundedHole(const FloatRect&amp;, const RoundedRect&amp; roundedHoleRect, const Color&amp;, ColorSpace);
</del><ins>+        void fillRoundedRect(const FloatRoundedRect&amp;, const Color&amp;, ColorSpace, BlendMode = BlendModeNormal);
+        void fillRectWithRoundedHole(const FloatRect&amp;, const FloatRoundedRect&amp; roundedHoleRect, const Color&amp;, ColorSpace);
</ins><span class="cx"> 
</span><span class="cx">         void clearRect(const FloatRect&amp;);
</span><span class="cx"> 
</span><span class="lines">@@ -327,13 +327,10 @@
</span><span class="cx"> 
</span><span class="cx">         void clip(const IntRect&amp;);
</span><span class="cx">         void clip(const FloatRect&amp;);
</span><del>-        void clipRoundedRect(const RoundedRect&amp;);
</del><ins>+        void clipRoundedRect(const FloatRoundedRect&amp;);
</ins><span class="cx"> 
</span><del>-        // FIXME: Consider writing this in terms of a specialized RoundedRect that uses FloatRect and FloatSize radii.
-        void clipRoundedRect(const FloatRect&amp;, const FloatSize&amp; topLeft, const FloatSize&amp; topRight, const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight);
-
</del><span class="cx">         void clipOut(const FloatRect&amp;);
</span><del>-        void clipOutRoundedRect(const RoundedRect&amp;);
</del><ins>+        void clipOutRoundedRect(const FloatRoundedRect&amp;);
</ins><span class="cx">         void clipPath(const Path&amp;, WindRule);
</span><span class="cx">         void clipConvexPolygon(size_t numPoints, const FloatPoint*, bool antialias = true);
</span><span class="cx">         void clipToImageBuffer(ImageBuffer*, const FloatRect&amp;);
</span><span class="lines">@@ -570,6 +567,8 @@
</span><span class="cx">         void platformFillEllipse(const FloatRect&amp;);
</span><span class="cx">         void platformStrokeEllipse(const FloatRect&amp;);
</span><span class="cx"> 
</span><ins>+        void platformFillRoundedRect(const FloatRoundedRect&amp;, const Color&amp;, ColorSpace);
+
</ins><span class="cx">         GraphicsContextPlatformPrivate* m_data;
</span><span class="cx"> 
</span><span class="cx">         GraphicsContextState m_state;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsPathcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/Path.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/Path.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/Path.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -31,6 +31,7 @@
</span><span class="cx"> 
</span><span class="cx"> #include &quot;FloatPoint.h&quot;
</span><span class="cx"> #include &quot;FloatRect.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;PathTraversalState.h&quot;
</span><span class="cx"> #include &quot;RoundedRect.h&quot;
</span><span class="cx"> #include &lt;math.h&gt;
</span><span class="lines">@@ -91,11 +92,6 @@
</span><span class="cx">     return traversalState.m_normalAngle;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void Path::addRoundedRect(const RoundedRect&amp; r)
-{
-    addRoundedRect(r.rect(), r.radii().topLeft(), r.radii().topRight(), r.radii().bottomLeft(), r.radii().bottomRight());
-}
-
</del><span class="cx"> void Path::addRoundedRect(const FloatRect&amp; rect, const FloatSize&amp; roundingRadii, RoundedRectStrategy strategy)
</span><span class="cx"> {
</span><span class="cx">     if (rect.isEmpty())
</span><span class="lines">@@ -105,7 +101,7 @@
</span><span class="cx">     FloatSize halfSize(rect.width() / 2, rect.height() / 2);
</span><span class="cx"> 
</span><span class="cx">     // Apply the SVG corner radius constraints, per the rect section of the SVG shapes spec: if
</span><del>-    // one of rx,ry is negative, then the other corner radius value is used. If both values are 
</del><ins>+    // one of rx,ry is negative, then the other corner radius value is used. If both values are
</ins><span class="cx">     // negative then rx = ry = 0. If rx is greater than half of the width of the rectangle
</span><span class="cx">     // then set rx to half of the width; ry is handled similarly.
</span><span class="cx"> 
</span><span class="lines">@@ -121,38 +117,38 @@
</span><span class="cx">     if (radius.height() &gt; halfSize.height())
</span><span class="cx">         radius.setHeight(halfSize.height());
</span><span class="cx"> 
</span><del>-    addPathForRoundedRect(rect, radius, radius, radius, radius, strategy);
</del><ins>+    addRoundedRect(FloatRoundedRect(rect, radius, radius, radius, radius), strategy);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-void Path::addRoundedRect(const FloatRect&amp; rect, const FloatSize&amp; topLeftRadius, const FloatSize&amp; topRightRadius, const FloatSize&amp; bottomLeftRadius, const FloatSize&amp; bottomRightRadius, RoundedRectStrategy strategy)
</del><ins>+void Path::addRoundedRect(const FloatRoundedRect&amp; r, RoundedRectStrategy strategy)
</ins><span class="cx"> {
</span><del>-    if (rect.isEmpty())
</del><ins>+    if (r.isEmpty())
</ins><span class="cx">         return;
</span><span class="cx"> 
</span><del>-    if (rect.width() &lt; topLeftRadius.width() + topRightRadius.width()
-            || rect.width() &lt; bottomLeftRadius.width() + bottomRightRadius.width()
-            || rect.height() &lt; topLeftRadius.height() + bottomLeftRadius.height()
-            || rect.height() &lt; topRightRadius.height() + bottomRightRadius.height()) {
</del><ins>+    const FloatRoundedRect::Radii&amp; radii = r.radii();
+    const FloatRect&amp; rect = r.rect();
+
+    if (!r.isRenderable()) {
</ins><span class="cx">         // If all the radii cannot be accommodated, return a rect.
</span><span class="cx">         addRect(rect);
</span><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    addPathForRoundedRect(rect, topLeftRadius, topRightRadius, bottomLeftRadius, bottomRightRadius, strategy);
-}
-
-void Path::addPathForRoundedRect(const FloatRect&amp; rect, const FloatSize&amp; topLeftRadius, const FloatSize&amp; topRightRadius, const FloatSize&amp; bottomLeftRadius, const FloatSize&amp; bottomRightRadius, RoundedRectStrategy strategy)
-{
</del><span class="cx">     if (strategy == PreferNativeRoundedRect) {
</span><span class="cx"> #if USE(CG)
</span><del>-        platformAddPathForRoundedRect(rect, topLeftRadius, topRightRadius, bottomLeftRadius, bottomRightRadius);
</del><ins>+        platformAddPathForRoundedRect(rect, radii.topLeft(), radii.topRight(), radii.bottomLeft(), radii.bottomRight());
</ins><span class="cx">         return;
</span><span class="cx"> #endif
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    addBeziersForRoundedRect(rect, topLeftRadius, topRightRadius, bottomLeftRadius, bottomRightRadius);
</del><ins>+    addBeziersForRoundedRect(rect, radii.topLeft(), radii.topRight(), radii.bottomLeft(), radii.bottomRight());
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void Path::addRoundedRect(const RoundedRect&amp; r)
+{
+    addRoundedRect(FloatRoundedRect(r));
+}
+
</ins><span class="cx"> // Approximation of control point positions on a bezier to simulate a quarter of a circle.
</span><span class="cx"> // This is 1-kappa, where kappa = 4 * (sqrt(2) - 1) / 3
</span><span class="cx"> static const float gCircleControlPoint = 0.447715f;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsPathh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/Path.h (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/Path.h        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/Path.h        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -57,6 +57,7 @@
</span><span class="cx">     class AffineTransform;
</span><span class="cx">     class FloatPoint;
</span><span class="cx">     class FloatRect;
</span><ins>+    class FloatRoundedRect;
</ins><span class="cx">     class FloatSize;
</span><span class="cx">     class GraphicsContext;
</span><span class="cx">     class RoundedRect;
</span><span class="lines">@@ -129,7 +130,7 @@
</span><span class="cx">         };
</span><span class="cx"> 
</span><span class="cx">         void addRoundedRect(const FloatRect&amp;, const FloatSize&amp; roundingRadii, RoundedRectStrategy = PreferNativeRoundedRect);
</span><del>-        void addRoundedRect(const FloatRect&amp;, const FloatSize&amp; topLeftRadius, const FloatSize&amp; topRightRadius, const FloatSize&amp; bottomLeftRadius, const FloatSize&amp; bottomRightRadius, RoundedRectStrategy = PreferNativeRoundedRect);
</del><ins>+        void addRoundedRect(const FloatRoundedRect&amp;, RoundedRectStrategy = PreferNativeRoundedRect);
</ins><span class="cx">         void addRoundedRect(const RoundedRect&amp;);
</span><span class="cx"> 
</span><span class="cx">         void translate(const FloatSize&amp;);
</span><span class="lines">@@ -143,7 +144,6 @@
</span><span class="cx">         void apply(void* info, PathApplierFunction) const;
</span><span class="cx">         void transform(const AffineTransform&amp;);
</span><span class="cx"> 
</span><del>-        void addPathForRoundedRect(const FloatRect&amp;, const FloatSize&amp; topLeftRadius, const FloatSize&amp; topRightRadius, const FloatSize&amp; bottomLeftRadius, const FloatSize&amp; bottomRightRadius, RoundedRectStrategy = PreferNativeRoundedRect);
</del><span class="cx">         void addBeziersForRoundedRect(const FloatRect&amp;, const FloatSize&amp; topLeftRadius, const FloatSize&amp; topRightRadius, const FloatSize&amp; bottomLeftRadius, const FloatSize&amp; bottomRightRadius);
</span><span class="cx"> 
</span><span class="cx"> #if USE(CG)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsRoundedRectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/RoundedRect.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/RoundedRect.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/RoundedRect.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -28,6 +28,7 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;RoundedRect.h&quot;
</span><span class="cx"> 
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;LayoutRect.h&quot;
</span><span class="cx"> #include &quot;LayoutUnit.h&quot;
</span><span class="cx"> 
</span><span class="lines">@@ -236,4 +237,9 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+FloatRoundedRect RoundedRect::pixelSnappedRoundedRectForPainting(float deviceScaleFactor) const
+{
+    return FloatRoundedRect(pixelSnappedForPainting(rect(), deviceScaleFactor), radii());
+}
+
</ins><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsRoundedRecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/RoundedRect.h (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/RoundedRect.h        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/RoundedRect.h        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -33,6 +33,7 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><ins>+class FloatRoundedRect;
</ins><span class="cx"> class LayoutUnit;
</span><span class="cx"> 
</span><span class="cx"> class RoundedRect {
</span><span class="lines">@@ -103,6 +104,8 @@
</span><span class="cx">     // This only works for convex quads.
</span><span class="cx">     bool intersectsQuad(const FloatQuad&amp;) const;
</span><span class="cx"> 
</span><ins>+    FloatRoundedRect pixelSnappedRoundedRectForPainting(float deviceScaleFactor) const;
+
</ins><span class="cx"> private:
</span><span class="cx">     LayoutRect m_rect;
</span><span class="cx">     Radii m_radii;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsShadowBlurcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/ShadowBlur.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/ShadowBlur.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/ShadowBlur.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -509,9 +509,9 @@
</span><span class="cx">                    templateSideLength + topSlice + bottomSlice);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ShadowBlur::drawRectShadow(GraphicsContext* graphicsContext, const FloatRect&amp; shadowedRect, const FloatRoundedRect::Radii&amp; radii)
</del><ins>+void ShadowBlur::drawRectShadow(GraphicsContext* graphicsContext, const FloatRoundedRect&amp; shadowedRect)
</ins><span class="cx"> {
</span><del>-    IntRect layerRect = calculateLayerBoundingRect(graphicsContext, shadowedRect, graphicsContext-&gt;clipBounds());
</del><ins>+    IntRect layerRect = calculateLayerBoundingRect(graphicsContext, shadowedRect.rect(), graphicsContext-&gt;clipBounds());
</ins><span class="cx">     if (layerRect.isEmpty())
</span><span class="cx">         return;
</span><span class="cx"> 
</span><span class="lines">@@ -520,23 +520,24 @@
</span><span class="cx">     // drawRectShadowWithTiling does not work with rotations.
</span><span class="cx">     // https://bugs.webkit.org/show_bug.cgi?id=45042
</span><span class="cx">     if (!graphicsContext-&gt;getCTM().preservesAxisAlignment() || m_type != BlurShadow) {
</span><del>-        drawRectShadowWithoutTiling(graphicsContext, shadowedRect, radii, layerRect);
</del><ins>+        drawRectShadowWithoutTiling(graphicsContext, shadowedRect, layerRect);
</ins><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     IntSize edgeSize = blurredEdgeSize();
</span><del>-    IntSize templateSize = this-&gt;templateSize(edgeSize, radii);
</del><ins>+    IntSize templateSize = this-&gt;templateSize(edgeSize, shadowedRect.radii());
+    const FloatRect&amp; rect = shadowedRect.rect();
</ins><span class="cx"> 
</span><del>-    if (templateSize.width() &gt; shadowedRect.width() || templateSize.height() &gt; shadowedRect.height()
</del><ins>+    if (templateSize.width() &gt; rect.width() || templateSize.height() &gt; rect.height()
</ins><span class="cx">         || (templateSize.width() * templateSize.height() &gt; m_sourceRect.width() * m_sourceRect.height())) {
</span><del>-        drawRectShadowWithoutTiling(graphicsContext, shadowedRect, radii, layerRect);
</del><ins>+        drawRectShadowWithoutTiling(graphicsContext, shadowedRect, layerRect);
</ins><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    drawRectShadowWithTiling(graphicsContext, shadowedRect, radii, templateSize, edgeSize);
</del><ins>+    drawRectShadowWithTiling(graphicsContext, shadowedRect, templateSize, edgeSize);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ShadowBlur::drawInsetShadow(GraphicsContext* graphicsContext, const FloatRect&amp; rect, const FloatRect&amp; holeRect, const FloatRoundedRect::Radii&amp; holeRadii)
</del><ins>+void ShadowBlur::drawInsetShadow(GraphicsContext* graphicsContext, const FloatRect&amp; rect, const FloatRoundedRect&amp; holeRect)
</ins><span class="cx"> {
</span><span class="cx">     IntRect layerRect = calculateLayerBoundingRect(graphicsContext, rect, graphicsContext-&gt;clipBounds());
</span><span class="cx">     if (layerRect.isEmpty())
</span><span class="lines">@@ -547,33 +548,34 @@
</span><span class="cx">     // drawInsetShadowWithTiling does not work with rotations.
</span><span class="cx">     // https://bugs.webkit.org/show_bug.cgi?id=45042
</span><span class="cx">     if (!graphicsContext-&gt;getCTM().preservesAxisAlignment() || m_type != BlurShadow) {
</span><del>-        drawInsetShadowWithoutTiling(graphicsContext, rect, holeRect, holeRadii, layerRect);
</del><ins>+        drawInsetShadowWithoutTiling(graphicsContext, rect, holeRect, layerRect);
</ins><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     IntSize edgeSize = blurredEdgeSize();
</span><del>-    IntSize templateSize = this-&gt;templateSize(edgeSize, holeRadii);
</del><ins>+    IntSize templateSize = this-&gt;templateSize(edgeSize, holeRect.radii());
+    const FloatRect&amp; hRect = holeRect.rect();
</ins><span class="cx"> 
</span><del>-    if (templateSize.width() &gt; holeRect.width() || templateSize.height() &gt; holeRect.height()
-        || (templateSize.width() * templateSize.height() &gt; holeRect.width() * holeRect.height())) {
-        drawInsetShadowWithoutTiling(graphicsContext, rect, holeRect, holeRadii, layerRect);
</del><ins>+    if (templateSize.width() &gt; hRect.width() || templateSize.height() &gt; hRect.height()
+        || (templateSize.width() * templateSize.height() &gt; hRect.width() * hRect.height())) {
+        drawInsetShadowWithoutTiling(graphicsContext, rect, holeRect, layerRect);
</ins><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    drawInsetShadowWithTiling(graphicsContext, rect, holeRect, holeRadii, templateSize, edgeSize);
</del><ins>+    drawInsetShadowWithTiling(graphicsContext, rect, holeRect, templateSize, edgeSize);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ShadowBlur::drawRectShadowWithoutTiling(GraphicsContext* graphicsContext, const FloatRect&amp; shadowedRect, const FloatRoundedRect::Radii&amp; radii, const IntRect&amp; layerRect)
</del><ins>+void ShadowBlur::drawRectShadowWithoutTiling(GraphicsContext* graphicsContext, const FloatRoundedRect&amp; shadowedRect, const IntRect&amp; layerRect)
</ins><span class="cx"> {
</span><span class="cx">     m_layerImage = ScratchBuffer::shared().getScratchBuffer(layerRect.size());
</span><span class="cx">     if (!m_layerImage)
</span><span class="cx">         return;
</span><span class="cx"> 
</span><del>-    FloatRect bufferRelativeShadowedRect = shadowedRect;
</del><ins>+    FloatRect bufferRelativeShadowedRect = shadowedRect.rect();
</ins><span class="cx">     bufferRelativeShadowedRect.move(m_layerContextTranslation);
</span><span class="cx"> 
</span><span class="cx">     // Only redraw in the scratch buffer if its cached contents don't match our needs
</span><del>-    bool redrawNeeded = ScratchBuffer::shared().setCachedShadowValues(m_blurRadius, Color::black, ColorSpaceDeviceRGB, bufferRelativeShadowedRect, radii, m_layerSize);
</del><ins>+    bool redrawNeeded = ScratchBuffer::shared().setCachedShadowValues(m_blurRadius, Color::black, ColorSpaceDeviceRGB, bufferRelativeShadowedRect, shadowedRect.radii(), m_layerSize);
</ins><span class="cx">     if (redrawNeeded) {
</span><span class="cx">         GraphicsContext* shadowContext = m_layerImage-&gt;context();
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*shadowContext);
</span><span class="lines">@@ -582,11 +584,11 @@
</span><span class="cx">         shadowContext-&gt;clearRect(FloatRect(0, 0, m_layerSize.width() + 1, m_layerSize.height() + 1));
</span><span class="cx">         shadowContext-&gt;translate(m_layerContextTranslation);
</span><span class="cx">         shadowContext-&gt;setFillColor(Color::black, ColorSpaceDeviceRGB);
</span><del>-        if (radii.isZero())
-            shadowContext-&gt;fillRect(shadowedRect);
</del><ins>+        if (shadowedRect.radii().isZero())
+            shadowContext-&gt;fillRect(shadowedRect.rect());
</ins><span class="cx">         else {
</span><span class="cx">             Path path;
</span><del>-            path.addRoundedRect(shadowedRect, radii.topLeft(), radii.topRight(), radii.bottomLeft(), radii.bottomRight());
</del><ins>+            path.addRoundedRect(shadowedRect);
</ins><span class="cx">             shadowContext-&gt;fillPath(path);
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -598,7 +600,7 @@
</span><span class="cx">     ScratchBuffer::shared().scheduleScratchBufferPurge();
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ShadowBlur::drawInsetShadowWithoutTiling(GraphicsContext* graphicsContext, const FloatRect&amp; rect, const FloatRect&amp; holeRect, const FloatRoundedRect::Radii&amp; holeRadii, const IntRect&amp; layerRect)
</del><ins>+void ShadowBlur::drawInsetShadowWithoutTiling(GraphicsContext* graphicsContext, const FloatRect&amp; rect, const FloatRoundedRect&amp; holeRect, const IntRect&amp; layerRect)
</ins><span class="cx"> {
</span><span class="cx">     m_layerImage = ScratchBuffer::shared().getScratchBuffer(layerRect.size());
</span><span class="cx">     if (!m_layerImage)
</span><span class="lines">@@ -607,11 +609,11 @@
</span><span class="cx">     FloatRect bufferRelativeRect = rect;
</span><span class="cx">     bufferRelativeRect.move(m_layerContextTranslation);
</span><span class="cx"> 
</span><del>-    FloatRect bufferRelativeHoleRect = holeRect;
</del><ins>+    FloatRect bufferRelativeHoleRect = holeRect.rect();
</ins><span class="cx">     bufferRelativeHoleRect.move(m_layerContextTranslation);
</span><span class="cx"> 
</span><span class="cx">     // Only redraw in the scratch buffer if its cached contents don't match our needs
</span><del>-    bool redrawNeeded = ScratchBuffer::shared().setCachedInsetShadowValues(m_blurRadius, Color::black, ColorSpaceDeviceRGB, bufferRelativeRect, bufferRelativeHoleRect, holeRadii);
</del><ins>+    bool redrawNeeded = ScratchBuffer::shared().setCachedInsetShadowValues(m_blurRadius, Color::black, ColorSpaceDeviceRGB, bufferRelativeRect, bufferRelativeHoleRect, holeRect.radii());
</ins><span class="cx">     if (redrawNeeded) {
</span><span class="cx">         GraphicsContext* shadowContext = m_layerImage-&gt;context();
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*shadowContext);
</span><span class="lines">@@ -622,10 +624,10 @@
</span><span class="cx"> 
</span><span class="cx">         Path path;
</span><span class="cx">         path.addRect(rect);
</span><del>-        if (holeRadii.isZero())
-            path.addRect(holeRect);
</del><ins>+        if (holeRect.radii().isZero())
+            path.addRect(holeRect.rect());
</ins><span class="cx">         else
</span><del>-            path.addRoundedRect(holeRect, holeRadii.topLeft(), holeRadii.topRight(), holeRadii.bottomLeft(), holeRadii.bottomRight());
</del><ins>+            path.addRoundedRect(holeRect);
</ins><span class="cx"> 
</span><span class="cx">         shadowContext-&gt;setFillRule(RULE_EVENODD);
</span><span class="cx">         shadowContext-&gt;setFillColor(Color::black, ColorSpaceDeviceRGB);
</span><span class="lines">@@ -671,7 +673,7 @@
</span><span class="cx">      the shadow.
</span><span class="cx">  */
</span><span class="cx"> 
</span><del>-void ShadowBlur::drawInsetShadowWithTiling(GraphicsContext* graphicsContext, const FloatRect&amp; rect, const FloatRect&amp; holeRect, const FloatRoundedRect::Radii&amp; radii, const IntSize&amp; templateSize, const IntSize&amp; edgeSize)
</del><ins>+void ShadowBlur::drawInsetShadowWithTiling(GraphicsContext* graphicsContext, const FloatRect&amp; rect, const FloatRoundedRect&amp; holeRect, const IntSize&amp; templateSize, const IntSize&amp; edgeSize)
</ins><span class="cx"> {
</span><span class="cx">     m_layerImage = ScratchBuffer::shared().getScratchBuffer(templateSize);
</span><span class="cx">     if (!m_layerImage)
</span><span class="lines">@@ -682,7 +684,7 @@
</span><span class="cx">     FloatRect templateHole = FloatRect(edgeSize.width(), edgeSize.height(), templateSize.width() - 2 * edgeSize.width(), templateSize.height() - 2 * edgeSize.height());
</span><span class="cx"> 
</span><span class="cx">     // Only redraw in the scratch buffer if its cached contents don't match our needs
</span><del>-    bool redrawNeeded = ScratchBuffer::shared().setCachedInsetShadowValues(m_blurRadius, m_color, m_colorSpace, templateBounds, templateHole, radii);
</del><ins>+    bool redrawNeeded = ScratchBuffer::shared().setCachedInsetShadowValues(m_blurRadius, m_color, m_colorSpace, templateBounds, templateHole, holeRect.radii());
</ins><span class="cx">     if (redrawNeeded) {
</span><span class="cx">         // Draw shadow into a new ImageBuffer.
</span><span class="cx">         GraphicsContext* shadowContext = m_layerImage-&gt;context();
</span><span class="lines">@@ -693,10 +695,10 @@
</span><span class="cx"> 
</span><span class="cx">         Path path;
</span><span class="cx">         path.addRect(templateBounds);
</span><del>-        if (radii.isZero())
</del><ins>+        if (holeRect.radii().isZero())
</ins><span class="cx">             path.addRect(templateHole);
</span><span class="cx">         else
</span><del>-            path.addRoundedRect(templateHole, radii.topLeft(), radii.topRight(), radii.bottomLeft(), radii.bottomRight());
</del><ins>+            path.addRoundedRect(FloatRoundedRect(templateHole, holeRect.radii()));
</ins><span class="cx"> 
</span><span class="cx">         shadowContext-&gt;fillPath(path);
</span><span class="cx"> 
</span><span class="lines">@@ -711,7 +713,7 @@
</span><span class="cx">     FloatRect boundingRect = rect;
</span><span class="cx">     boundingRect.move(offset);
</span><span class="cx"> 
</span><del>-    FloatRect destHoleRect = holeRect;
</del><ins>+    FloatRect destHoleRect = holeRect.rect();
</ins><span class="cx">     destHoleRect.move(offset);
</span><span class="cx">     FloatRect destHoleBounds = destHoleRect;
</span><span class="cx">     destHoleBounds.inflateX(edgeSize.width());
</span><span class="lines">@@ -730,13 +732,13 @@
</span><span class="cx">         graphicsContext-&gt;fillPath(exteriorPath);
</span><span class="cx">     }
</span><span class="cx">     
</span><del>-    drawLayerPieces(graphicsContext, destHoleBounds, radii, edgeSize, templateSize, InnerShadow);
</del><ins>+    drawLayerPieces(graphicsContext, destHoleBounds, holeRect.radii(), edgeSize, templateSize, InnerShadow);
</ins><span class="cx"> 
</span><span class="cx">     m_layerImage = 0;
</span><span class="cx">     ScratchBuffer::shared().scheduleScratchBufferPurge();
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ShadowBlur::drawRectShadowWithTiling(GraphicsContext* graphicsContext, const FloatRect&amp; shadowedRect, const FloatRoundedRect::Radii&amp; radii, const IntSize&amp; templateSize, const IntSize&amp; edgeSize)
</del><ins>+void ShadowBlur::drawRectShadowWithTiling(GraphicsContext* graphicsContext, const FloatRoundedRect&amp; shadowedRect, const IntSize&amp; templateSize, const IntSize&amp; edgeSize)
</ins><span class="cx"> {
</span><span class="cx">     m_layerImage = ScratchBuffer::shared().getScratchBuffer(templateSize);
</span><span class="cx">     if (!m_layerImage)
</span><span class="lines">@@ -745,7 +747,7 @@
</span><span class="cx">     FloatRect templateShadow = FloatRect(edgeSize.width(), edgeSize.height(), templateSize.width() - 2 * edgeSize.width(), templateSize.height() - 2 * edgeSize.height());
</span><span class="cx"> 
</span><span class="cx">     // Only redraw in the scratch buffer if its cached contents don't match our needs
</span><del>-    bool redrawNeeded = ScratchBuffer::shared().setCachedShadowValues(m_blurRadius, m_color, m_colorSpace, templateShadow, radii, m_layerSize);
</del><ins>+    bool redrawNeeded = ScratchBuffer::shared().setCachedShadowValues(m_blurRadius, m_color, m_colorSpace, templateShadow, shadowedRect.radii(), m_layerSize);
</ins><span class="cx">     if (redrawNeeded) {
</span><span class="cx">         // Draw shadow into the ImageBuffer.
</span><span class="cx">         GraphicsContext* shadowContext = m_layerImage-&gt;context();
</span><span class="lines">@@ -754,11 +756,11 @@
</span><span class="cx">         shadowContext-&gt;clearRect(FloatRect(0, 0, templateSize.width(), templateSize.height()));
</span><span class="cx">         shadowContext-&gt;setFillColor(Color::black, ColorSpaceDeviceRGB);
</span><span class="cx">         
</span><del>-        if (radii.isZero())
</del><ins>+        if (shadowedRect.radii().isZero())
</ins><span class="cx">             shadowContext-&gt;fillRect(templateShadow);
</span><span class="cx">         else {
</span><span class="cx">             Path path;
</span><del>-            path.addRoundedRect(templateShadow, radii.topLeft(), radii.topRight(), radii.bottomLeft(), radii.bottomRight());
</del><ins>+            path.addRoundedRect(FloatRoundedRect(templateShadow, shadowedRect.radii()));
</ins><span class="cx">             shadowContext-&gt;fillPath(path);
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -770,12 +772,12 @@
</span><span class="cx">         offset.scale(1 / transform.xScale(), 1 / transform.yScale());
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    FloatRect shadowBounds = shadowedRect;
</del><ins>+    FloatRect shadowBounds = shadowedRect.rect();
</ins><span class="cx">     shadowBounds.move(offset);
</span><span class="cx">     shadowBounds.inflateX(edgeSize.width());
</span><span class="cx">     shadowBounds.inflateY(edgeSize.height());
</span><span class="cx"> 
</span><del>-    drawLayerPieces(graphicsContext, shadowBounds, radii, edgeSize, templateSize, OuterShadow);
</del><ins>+    drawLayerPieces(graphicsContext, shadowBounds, shadowedRect.radii(), edgeSize, templateSize, OuterShadow);
</ins><span class="cx"> 
</span><span class="cx">     m_layerImage = 0;
</span><span class="cx">     ScratchBuffer::shared().scheduleScratchBufferPurge();
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsShadowBlurh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/ShadowBlur.h (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/ShadowBlur.h        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/ShadowBlur.h        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -63,8 +63,8 @@
</span><span class="cx">     GraphicsContext* beginShadowLayer(GraphicsContext*, const FloatRect&amp; layerArea);
</span><span class="cx">     void endShadowLayer(GraphicsContext*);
</span><span class="cx"> 
</span><del>-    void drawRectShadow(GraphicsContext*, const FloatRect&amp;, const FloatRoundedRect::Radii&amp;);
-    void drawInsetShadow(GraphicsContext*, const FloatRect&amp;, const FloatRect&amp; holeRect, const FloatRoundedRect::Radii&amp; holeRadii);
</del><ins>+    void drawRectShadow(GraphicsContext*, const FloatRoundedRect&amp;);
+    void drawInsetShadow(GraphicsContext*, const FloatRect&amp;, const FloatRoundedRect&amp; holeRect);
</ins><span class="cx"> 
</span><span class="cx">     void blurLayerImage(unsigned char*, const IntSize&amp;, int stride);
</span><span class="cx"> 
</span><span class="lines">@@ -87,11 +87,11 @@
</span><span class="cx">     IntRect calculateLayerBoundingRect(GraphicsContext*, const FloatRect&amp; layerArea, const IntRect&amp; clipRect);
</span><span class="cx">     IntSize templateSize(const IntSize&amp; blurredEdgeSize, const FloatRoundedRect::Radii&amp;) const;
</span><span class="cx"> 
</span><del>-    void drawRectShadowWithoutTiling(GraphicsContext*, const FloatRect&amp;, const FloatRoundedRect::Radii&amp;, const IntRect&amp; layerRect);
-    void drawRectShadowWithTiling(GraphicsContext*, const FloatRect&amp;, const FloatRoundedRect::Radii&amp;, const IntSize&amp; shadowTemplateSize, const IntSize&amp; blurredEdgeSize);
</del><ins>+    void drawRectShadowWithoutTiling(GraphicsContext*, const FloatRoundedRect&amp;, const IntRect&amp; layerRect);
+    void drawRectShadowWithTiling(GraphicsContext*, const FloatRoundedRect&amp;, const IntSize&amp; shadowTemplateSize, const IntSize&amp; blurredEdgeSize);
</ins><span class="cx"> 
</span><del>-    void drawInsetShadowWithoutTiling(GraphicsContext*, const FloatRect&amp;, const FloatRect&amp; holeRect, const FloatRoundedRect::Radii&amp;, const IntRect&amp; layerRect);
-    void drawInsetShadowWithTiling(GraphicsContext*, const FloatRect&amp;, const FloatRect&amp; holeRect, const FloatRoundedRect::Radii&amp;, const IntSize&amp; shadowTemplateSize, const IntSize&amp; blurredEdgeSize);
</del><ins>+    void drawInsetShadowWithoutTiling(GraphicsContext*, const FloatRect&amp;, const FloatRoundedRect&amp; holeRect, const IntRect&amp; layerRect);
+    void drawInsetShadowWithTiling(GraphicsContext*, const FloatRect&amp;, const FloatRoundedRect&amp; holeRect, const IntSize&amp; shadowTemplateSize, const IntSize&amp; blurredEdgeSize);
</ins><span class="cx">     
</span><span class="cx">     void drawLayerPieces(GraphicsContext*, const FloatRect&amp; shadowBounds, const FloatRoundedRect::Radii&amp;, const IntSize&amp; roundedRadius, const IntSize&amp; templateSize, ShadowDirection);
</span><span class="cx">     
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicscairoGraphicsContextCairocpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextCairo.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextCairo.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextCairo.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -40,7 +40,7 @@
</span><span class="cx"> #include &quot;DrawErrorUnderline.h&quot;
</span><span class="cx"> #include &quot;FloatConversion.h&quot;
</span><span class="cx"> #include &quot;FloatRect.h&quot;
</span><del>-#include &quot;Font.h&quot;
</del><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;GraphicsContextPlatformPrivateCairo.h&quot;
</span><span class="cx"> #include &quot;IntRect.h&quot;
</span><span class="cx"> #include &quot;NotImplemented.h&quot;
</span><span class="lines">@@ -460,7 +460,7 @@
</span><span class="cx">         return;
</span><span class="cx"> 
</span><span class="cx">     if (hasShadow())
</span><del>-        platformContext()-&gt;shadowBlur().drawRectShadow(this, rect, RoundedRect::Radii());
</del><ins>+        platformContext()-&gt;shadowBlur().drawRectShadow(this, FloatRoundedRect(rect));
</ins><span class="cx"> 
</span><span class="cx">     fillRectWithColor(platformContext()-&gt;cr(), rect, color);
</span><span class="cx"> }
</span><span class="lines">@@ -1032,31 +1032,31 @@
</span><span class="cx">     cairo_set_fill_rule(cr, savedFillRule);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void GraphicsContext::fillRoundedRect(const FloatRect&amp; r, const FloatSize&amp; topLeft, const FloatSize&amp; topRight, const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight, const Color&amp; color, ColorSpace)
</del><ins>+void GraphicsContext::platformFillRoundedRect(const FloatRoundedRect&amp; rect, const Color&amp; color, ColorSpace)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled())
</span><span class="cx">         return;
</span><span class="cx"> 
</span><span class="cx">     if (hasShadow())
</span><del>-        platformContext()-&gt;shadowBlur().drawRectShadow(this, r, FloatRoundedRect::Radii(topLeft, topRight, bottomLeft, bottomRight));
</del><ins>+        platformContext()-&gt;shadowBlur().drawRectShadow(this, rect);
</ins><span class="cx"> 
</span><span class="cx">     cairo_t* cr = platformContext()-&gt;cr();
</span><span class="cx">     cairo_save(cr);
</span><span class="cx">     Path path;
</span><del>-    path.addRoundedRect(r, topLeft, topRight, bottomLeft, bottomRight);
</del><ins>+    path.addRoundedRect(rect);
</ins><span class="cx">     appendWebCorePathToCairoContext(cr, path);
</span><span class="cx">     setSourceRGBAFromColor(cr, color);
</span><span class="cx">     cairo_fill(cr);
</span><span class="cx">     cairo_restore(cr);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void GraphicsContext::fillRectWithRoundedHole(const FloatRect&amp; rect, const RoundedRect&amp; roundedHoleRect, const Color&amp; color, ColorSpace)
</del><ins>+void GraphicsContext::fillRectWithRoundedHole(const FloatRect&amp; rect, const FloatRoundedRect&amp; roundedHoleRect, const Color&amp; color, ColorSpace)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled() || !color.isValid())
</span><span class="cx">         return;
</span><span class="cx"> 
</span><span class="cx">     if (this-&gt;mustUseShadowBlur())
</span><del>-        platformContext()-&gt;shadowBlur().drawInsetShadow(this, rect, roundedHoleRect.rect(), roundedHoleRect.radii());
</del><ins>+        platformContext()-&gt;shadowBlur().drawInsetShadow(this, rect, roundedHoleRect);
</ins><span class="cx"> 
</span><span class="cx">     Path path;
</span><span class="cx">     path.addRect(rect);
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicscgGraphicsContextCGcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -806,7 +806,7 @@
</span><span class="cx">         CGContextSetShadowWithColor(platformContext(), CGSizeZero, 0, 0);
</span><span class="cx"> 
</span><span class="cx">         ShadowBlur contextShadow(m_state);
</span><del>-        contextShadow.drawRectShadow(this, rect, RoundedRect::Radii());
</del><ins>+        contextShadow.drawRectShadow(this, FloatRoundedRect(rect));
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     CGContextFillRect(context, rect);
</span><span class="lines">@@ -834,7 +834,7 @@
</span><span class="cx">         CGContextSetShadowWithColor(platformContext(), CGSizeZero, 0, 0);
</span><span class="cx"> 
</span><span class="cx">         ShadowBlur contextShadow(m_state);
</span><del>-        contextShadow.drawRectShadow(this, rect, RoundedRect::Radii());
</del><ins>+        contextShadow.drawRectShadow(this, FloatRoundedRect(rect));
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     CGContextFillRect(context, rect);
</span><span class="lines">@@ -846,7 +846,7 @@
</span><span class="cx">         setCGFillColor(context, oldFillColor, oldColorSpace);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void GraphicsContext::fillRoundedRect(const FloatRect&amp; rect, const FloatSize&amp; topLeft, const FloatSize&amp; topRight, const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight, const Color&amp; color, ColorSpace colorSpace)
</del><ins>+void GraphicsContext::platformFillRoundedRect(const FloatRoundedRect&amp; rect, const Color&amp; color, ColorSpace colorSpace)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled())
</span><span class="cx">         return;
</span><span class="lines">@@ -865,17 +865,19 @@
</span><span class="cx">         CGContextSetShadowWithColor(platformContext(), CGSizeZero, 0, 0);
</span><span class="cx"> 
</span><span class="cx">         ShadowBlur contextShadow(m_state);
</span><del>-        contextShadow.drawRectShadow(this, rect, FloatRoundedRect::Radii(topLeft, topRight, bottomLeft, bottomRight));
</del><ins>+        contextShadow.drawRectShadow(this, rect);
</ins><span class="cx">     }
</span><span class="cx"> 
</span><del>-    bool equalWidths = (topLeft.width() == topRight.width() &amp;&amp; topRight.width() == bottomLeft.width() &amp;&amp; bottomLeft.width() == bottomRight.width());
-    bool equalHeights = (topLeft.height() == bottomLeft.height() &amp;&amp; bottomLeft.height() == topRight.height() &amp;&amp; topRight.height() == bottomRight.height());
</del><ins>+    const FloatRect&amp; r = rect.rect();
+    const FloatRoundedRect::Radii&amp; radii = rect.radii();
+    bool equalWidths = (radii.topLeft().width() == radii.topRight().width() &amp;&amp; radii.topRight().width() == radii.bottomLeft().width() &amp;&amp; radii.bottomLeft().width() == radii.bottomRight().width());
+    bool equalHeights = (radii.topLeft().height() == radii.bottomLeft().height() &amp;&amp; radii.bottomLeft().height() == radii.topRight().height() &amp;&amp; radii.topRight().height() == radii.bottomRight().height());
</ins><span class="cx">     bool hasCustomFill = m_state.fillGradient || m_state.fillPattern;
</span><del>-    if (!hasCustomFill &amp;&amp; equalWidths &amp;&amp; equalHeights &amp;&amp; topLeft.width() * 2 == rect.width() &amp;&amp; topLeft.height() * 2 == rect.height())
-        CGContextFillEllipseInRect(context, rect);
</del><ins>+    if (!hasCustomFill &amp;&amp; equalWidths &amp;&amp; equalHeights &amp;&amp; radii.topLeft().width() * 2 == r.width() &amp;&amp; radii.topLeft().height() * 2 == r.height())
+        CGContextFillEllipseInRect(context, r);
</ins><span class="cx">     else {
</span><span class="cx">         Path path;
</span><del>-        path.addRoundedRect(rect, topLeft, topRight, bottomLeft, bottomRight);
</del><ins>+        path.addRoundedRect(rect);
</ins><span class="cx">         fillPath(path);
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="lines">@@ -886,7 +888,7 @@
</span><span class="cx">         setCGFillColor(context, oldFillColor, oldColorSpace);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void GraphicsContext::fillRectWithRoundedHole(const FloatRect&amp; rect, const RoundedRect&amp; roundedHoleRect, const Color&amp; color, ColorSpace colorSpace)
</del><ins>+void GraphicsContext::fillRectWithRoundedHole(const FloatRect&amp; rect, const FloatRoundedRect&amp; roundedHoleRect, const Color&amp; color, ColorSpace colorSpace)
</ins><span class="cx"> {
</span><span class="cx">     if (paintingDisabled())
</span><span class="cx">         return;
</span><span class="lines">@@ -916,7 +918,7 @@
</span><span class="cx">         CGContextSetShadowWithColor(platformContext(), CGSizeZero, 0, 0);
</span><span class="cx"> 
</span><span class="cx">         ShadowBlur contextShadow(m_state);
</span><del>-        contextShadow.drawInsetShadow(this, rect, roundedHoleRect.rect(), roundedHoleRect.radii());
</del><ins>+        contextShadow.drawInsetShadow(this, rect, roundedHoleRect);
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     fillPath(path);
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicswinceGraphicsContextWinCEcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/wince/GraphicsContextWinCE.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/wince/GraphicsContextWinCE.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/graphics/wince/GraphicsContextWinCE.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -23,6 +23,7 @@
</span><span class="cx"> #include &quot;GraphicsContext.h&quot;
</span><span class="cx"> 
</span><span class="cx"> #include &quot;AffineTransform.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;Font.h&quot;
</span><span class="cx"> #include &quot;GDIExtras.h&quot;
</span><span class="cx"> #include &quot;GlyphBuffer.h&quot;
</span><span class="lines">@@ -1152,7 +1153,8 @@
</span><span class="cx"> {
</span><span class="cx">     return IntPoint(rect.left + (rect.right - rect.left) / 2, rect.top + (rect.bottom - rect.top) / 2);
</span><span class="cx"> }
</span><del>-void GraphicsContext::fillRoundedRect(const FloatRect&amp; fillRect, const FloatSize&amp; topLeft, const FloatSize&amp; topRight, const FloatSize&amp; bottomLeft, const FloatSize&amp; bottomRight, const Color&amp; c, ColorSpace colorSpace)
</del><ins>+
+void GraphicsContext::fillRoundedRect(const FloatRoundedRect&amp; rect, const Color&amp; c, ColorSpace colorSpace)
</ins><span class="cx"> {
</span><span class="cx">     ScopeDCProvider dcProvider(m_data);
</span><span class="cx">     if (!m_data-&gt;m_dc)
</span><span class="lines">@@ -1165,16 +1167,17 @@
</span><span class="cx">         
</span><span class="cx">     getShadow(shadowOffset, shadowBlur, shadowColor, shadowColorSpace);
</span><span class="cx">     
</span><ins>+    const FloatRect&amp; fillRect = rect.rect();
</ins><span class="cx">     IntRect dstRect = fillRect;
</span><span class="cx">     
</span><span class="cx">     dstRect.move(stableRound(shadowOffset.width()), stableRound(shadowOffset.height()));
</span><span class="cx">     dstRect.inflate(stableRound(shadowBlur));
</span><span class="cx">     dstRect = m_data-&gt;mapRect(dstRect);
</span><span class="cx">   
</span><del>-    FloatSize newTopLeft(m_data-&gt;mapSize(topLeft));
-    FloatSize newTopRight(m_data-&gt;mapSize(topRight));
-    FloatSize newBottomLeft(m_data-&gt;mapSize(bottomLeft));
-    FloatSize newBottomRight(m_data-&gt;mapSize(bottomRight));
</del><ins>+    FloatSize newTopLeft(m_data-&gt;mapSize(rect.radii().topLeft()));
+    FloatSize newTopRight(m_data-&gt;mapSize(rect.radii().topRight()));
+    FloatSize newBottomLeft(m_data-&gt;mapSize(rect.radii().bottomLeft()));
+    FloatSize newBottomRight(m_data-&gt;mapSize(rect.radii().bottomRight()));
</ins><span class="cx"> 
</span><span class="cx">     TransparentLayerDC transparentDc(m_data, dstRect, &amp;fillRect);
</span><span class="cx">     HDC dc = transparentDc.hdc();
</span><span class="lines">@@ -1225,7 +1228,6 @@
</span><span class="cx">     SelectObject(dc, oldBrush);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-
</del><span class="cx"> void GraphicsContext::drawRoundCorner(bool needsNewClip, RECT clipRect, RECT rectWin, HDC dc, int width, int height)
</span><span class="cx"> {
</span><span class="cx">     if (!dc)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgtkRenderThemeGtkcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/gtk/RenderThemeGtk.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/gtk/RenderThemeGtk.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/gtk/RenderThemeGtk.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -578,9 +578,9 @@
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-static RoundedRect::Radii borderRadiiFromStyle(RenderStyle* style)
</del><ins>+static FloatRoundedRect::Radii borderRadiiFromStyle(RenderStyle* style)
</ins><span class="cx"> {
</span><del>-    return RoundedRect::Radii(
</del><ins>+    return FloatRoundedRect::Radii(
</ins><span class="cx">         IntSize(style-&gt;borderTopLeftRadius().width().intValue(), style-&gt;borderTopLeftRadius().height().intValue()),
</span><span class="cx">         IntSize(style-&gt;borderTopRightRadius().width().intValue(), style-&gt;borderTopRightRadius().height().intValue()),
</span><span class="cx">         IntSize(style-&gt;borderBottomLeftRadius().width().intValue(), style-&gt;borderBottomLeftRadius().height().intValue()),
</span><span class="lines">@@ -613,7 +613,7 @@
</span><span class="cx">         rangeRect.setWidth(lengthRatio * totalTrackWidth);
</span><span class="cx">         if (index)
</span><span class="cx">             rangeRect.move(startRatio * totalTrackWidth, 0);
</span><del>-        context-&gt;fillRoundedRect(RoundedRect(rangeRect, borderRadiiFromStyle(style)), style-&gt;visitedDependentColor(CSSPropertyColor), style-&gt;colorSpace());
</del><ins>+        context-&gt;fillRoundedRect(FloatRoundedRect(rangeRect, borderRadiiFromStyle(style)), style-&gt;visitedDependentColor(CSSPropertyColor), style-&gt;colorSpace());
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     context-&gt;restore();
</span><span class="lines">@@ -623,7 +623,7 @@
</span><span class="cx"> bool RenderThemeGtk::paintMediaSliderThumb(RenderObject* o, const PaintInfo&amp; paintInfo, const IntRect&amp; r)
</span><span class="cx"> {
</span><span class="cx">     RenderStyle* style = &amp;o-&gt;style();
</span><del>-    paintInfo.context-&gt;fillRoundedRect(RoundedRect(r, borderRadiiFromStyle(style)), style-&gt;visitedDependentColor(CSSPropertyColor), style-&gt;colorSpace());
</del><ins>+    paintInfo.context-&gt;fillRoundedRect(FloatRoundedRect(r, borderRadiiFromStyle(style)), style-&gt;visitedDependentColor(CSSPropertyColor), style-&gt;colorSpace());
</ins><span class="cx">     return false;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -653,7 +653,7 @@
</span><span class="cx">     volumeRect.move(0, rectHeight - trackHeight);
</span><span class="cx">     volumeRect.setHeight(ceil(trackHeight));
</span><span class="cx"> 
</span><del>-    context-&gt;fillRoundedRect(RoundedRect(volumeRect, borderRadiiFromStyle(style)),
</del><ins>+    context-&gt;fillRoundedRect(FloatRoundedRect(volumeRect, borderRadiiFromStyle(style)),
</ins><span class="cx">         style-&gt;visitedDependentColor(CSSPropertyColor), style-&gt;colorSpace());
</span><span class="cx">     context-&gt;restore();
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformwinDragImageWincpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/win/DragImageWin.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/win/DragImageWin.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/platform/win/DragImageWin.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -26,6 +26,7 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;DragImage.h&quot;
</span><span class="cx"> 
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;Font.h&quot;
</span><span class="cx"> #include &quot;FontCache.h&quot;
</span><span class="cx"> #include &quot;FontDescription.h&quot;
</span><span class="lines">@@ -195,7 +196,7 @@
</span><span class="cx">     static const Color backgroundColor(140, 140, 140);
</span><span class="cx">     static const IntSize radii(DragLabelRadius, DragLabelRadius);
</span><span class="cx">     IntRect rect(0, 0, imageSize.width(), imageSize.height());
</span><del>-    context.fillRoundedRect(rect, radii, radii, radii, radii, backgroundColor, ColorSpaceDeviceRGB);
</del><ins>+    context.fillRoundedRect(FloatRoundedRect(rect, radii, radii, radii, radii), backgroundColor, ColorSpaceDeviceRGB);
</ins><span class="cx">  
</span><span class="cx">     // Draw the text
</span><span class="cx">     static const Color topColor(0, 0, 0, 255); // original alpha = 0.75
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderBoxcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderBox.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderBox.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/RenderBox.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -30,6 +30,7 @@
</span><span class="cx"> #include &quot;Document.h&quot;
</span><span class="cx"> #include &quot;EventHandler.h&quot;
</span><span class="cx"> #include &quot;FloatQuad.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;Frame.h&quot;
</span><span class="cx"> #include &quot;FrameView.h&quot;
</span><span class="cx"> #include &quot;GraphicsContext.h&quot;
</span><span class="lines">@@ -1211,7 +1212,7 @@
</span><span class="cx">         // beginning the layer).
</span><span class="cx">         RoundedRect border = style().getRoundedBorderFor(paintRect, &amp;view());
</span><span class="cx">         stateSaver.save();
</span><del>-        paintInfo.context-&gt;clipRoundedRect(border);
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(border));
</ins><span class="cx">         paintInfo.context-&gt;beginTransparencyLayer(1);
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="lines">@@ -1648,7 +1649,7 @@
</span><span class="cx">     IntRect clipRect = pixelSnappedIntRect(isControlClip ? controlClipRect(accumulatedOffset) : overflowClipRect(accumulatedOffset, paintInfo.renderNamedFlowFragment, IgnoreOverlayScrollbarSize, paintInfo.phase));
</span><span class="cx">     paintInfo.context-&gt;save();
</span><span class="cx">     if (style().hasBorderRadius())
</span><del>-        paintInfo.context-&gt;clipRoundedRect(style().getRoundedInnerBorderFor(LayoutRect(accumulatedOffset, size())));
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(style().getRoundedInnerBorderFor(LayoutRect(accumulatedOffset, size()))));
</ins><span class="cx">     paintInfo.context-&gt;clip(clipRect);
</span><span class="cx">     return true;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderBoxModelObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderBoxModelObject.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderBoxModelObject.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/RenderBoxModelObject.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -26,6 +26,7 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;RenderBoxModelObject.h&quot;
</span><span class="cx"> 
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;Frame.h&quot;
</span><span class="cx"> #include &quot;FrameView.h&quot;
</span><span class="cx"> #include &quot;GraphicsContext.h&quot;
</span><span class="lines">@@ -500,31 +501,31 @@
</span><span class="cx"> void RenderBoxModelObject::clipRoundedInnerRect(GraphicsContext * context, const LayoutRect&amp; rect, const RoundedRect&amp; clipRect)
</span><span class="cx"> {
</span><span class="cx">     if (clipRect.isRenderable())
</span><del>-        context-&gt;clipRoundedRect(clipRect);
</del><ins>+        context-&gt;clipRoundedRect(FloatRoundedRect(clipRect));
</ins><span class="cx">     else {
</span><span class="cx">         // We create a rounded rect for each of the corners and clip it, while making sure we clip opposing corners together.
</span><span class="cx">         if (!clipRect.radii().topLeft().isEmpty() || !clipRect.radii().bottomRight().isEmpty()) {
</span><del>-            IntRect topCorner(clipRect.rect().x(), clipRect.rect().y(), rect.maxX() - clipRect.rect().x(), rect.maxY() - clipRect.rect().y());
-            RoundedRect::Radii topCornerRadii;
</del><ins>+            FloatRect topCorner(clipRect.rect().x(), clipRect.rect().y(), rect.maxX() - clipRect.rect().x(), rect.maxY() - clipRect.rect().y());
+            FloatRoundedRect::Radii topCornerRadii;
</ins><span class="cx">             topCornerRadii.setTopLeft(clipRect.radii().topLeft());
</span><del>-            context-&gt;clipRoundedRect(RoundedRect(topCorner, topCornerRadii));
</del><ins>+            context-&gt;clipRoundedRect(FloatRoundedRect(topCorner, topCornerRadii));
</ins><span class="cx"> 
</span><del>-            IntRect bottomCorner(rect.x(), rect.y(), clipRect.rect().maxX() - rect.x(), clipRect.rect().maxY() - rect.y());
-            RoundedRect::Radii bottomCornerRadii;
</del><ins>+            FloatRect bottomCorner(rect.x(), rect.y(), clipRect.rect().maxX() - rect.x(), clipRect.rect().maxY() - rect.y());
+            FloatRoundedRect::Radii bottomCornerRadii;
</ins><span class="cx">             bottomCornerRadii.setBottomRight(clipRect.radii().bottomRight());
</span><del>-            context-&gt;clipRoundedRect(RoundedRect(bottomCorner, bottomCornerRadii));
</del><ins>+            context-&gt;clipRoundedRect(FloatRoundedRect(bottomCorner, bottomCornerRadii));
</ins><span class="cx">         } 
</span><span class="cx"> 
</span><span class="cx">         if (!clipRect.radii().topRight().isEmpty() || !clipRect.radii().bottomLeft().isEmpty()) {
</span><del>-            IntRect topCorner(rect.x(), clipRect.rect().y(), clipRect.rect().maxX() - rect.x(), rect.maxY() - clipRect.rect().y());
-            RoundedRect::Radii topCornerRadii;
</del><ins>+            FloatRect topCorner(rect.x(), clipRect.rect().y(), clipRect.rect().maxX() - rect.x(), rect.maxY() - clipRect.rect().y());
+            FloatRoundedRect::Radii topCornerRadii;
</ins><span class="cx">             topCornerRadii.setTopRight(clipRect.radii().topRight());
</span><del>-            context-&gt;clipRoundedRect(RoundedRect(topCorner, topCornerRadii));
</del><ins>+            context-&gt;clipRoundedRect(FloatRoundedRect(topCorner, topCornerRadii));
</ins><span class="cx"> 
</span><del>-            IntRect bottomCorner(clipRect.rect().x(), rect.y(), rect.maxX() - clipRect.rect().x(), clipRect.rect().maxY() - rect.y());
-            RoundedRect::Radii bottomCornerRadii;
</del><ins>+            FloatRect bottomCorner(clipRect.rect().x(), rect.y(), rect.maxX() - clipRect.rect().x(), clipRect.rect().maxY() - rect.y());
+            FloatRoundedRect::Radii bottomCornerRadii;
</ins><span class="cx">             bottomCornerRadii.setBottomLeft(clipRect.radii().bottomLeft());
</span><del>-            context-&gt;clipRoundedRect(RoundedRect(bottomCorner, bottomCornerRadii));
</del><ins>+            context-&gt;clipRoundedRect(FloatRoundedRect(bottomCorner, bottomCornerRadii));
</ins><span class="cx">         }
</span><span class="cx">     }
</span><span class="cx"> }
</span><span class="lines">@@ -653,7 +654,7 @@
</span><span class="cx">         if (hasRoundedBorder &amp;&amp; bleedAvoidance != BackgroundBleedUseTransparencyLayer) {
</span><span class="cx">             RoundedRect border = backgroundRoundedRectAdjustedForBleedAvoidance(*context, rect, bleedAvoidance, box, boxSize, includeLeftEdge, includeRightEdge);
</span><span class="cx">             if (border.isRenderable())
</span><del>-                context-&gt;fillRoundedRect(border, bgColor, style().colorSpace());
</del><ins>+                context-&gt;fillRoundedRect(FloatRoundedRect(border), bgColor, style().colorSpace());
</ins><span class="cx">             else {
</span><span class="cx">                 context-&gt;save();
</span><span class="cx">                 clipRoundedInnerRect(context, rect, border);
</span><span class="lines">@@ -1956,11 +1957,11 @@
</span><span class="cx">     if (clipToOuterBorder) {
</span><span class="cx">         // Clip to the inner and outer radii rects.
</span><span class="cx">         if (bleedAvoidance != BackgroundBleedUseTransparencyLayer)
</span><del>-            graphicsContext-&gt;clipRoundedRect(outerBorder);
</del><ins>+            graphicsContext-&gt;clipRoundedRect(FloatRoundedRect(outerBorder));
</ins><span class="cx">         // isRenderable() check avoids issue described in https://bugs.webkit.org/show_bug.cgi?id=38787
</span><span class="cx">         // The inside will be clipped out later (in clipBorderSideForComplexInnerPath)
</span><span class="cx">         if (innerBorder.isRenderable())
</span><del>-            graphicsContext-&gt;clipOutRoundedRect(innerBorder);
</del><ins>+            graphicsContext-&gt;clipOutRoundedRect(FloatRoundedRect(innerBorder));
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     // If only one edge visible antialiasing doesn't create seams
</span><span class="lines">@@ -2053,7 +2054,7 @@
</span><span class="cx">                 innerBorderTopWidth, innerBorderBottomWidth, innerBorderLeftWidth, innerBorderRightWidth,
</span><span class="cx">                 includeLogicalLeftEdge, includeLogicalRightEdge);
</span><span class="cx">             
</span><del>-            graphicsContext-&gt;clipRoundedRect(innerClip);
</del><ins>+            graphicsContext-&gt;clipRoundedRect(FloatRoundedRect(innerClip));
</ins><span class="cx">             drawBoxSideFromPath(graphicsContext, borderRect, borderPath, edges, thickness, drawThickness, side, style, color, SOLID, bleedAvoidance, includeLogicalLeftEdge, includeLogicalRightEdge);
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -2072,7 +2073,7 @@
</span><span class="cx">             RoundedRect outerClip = style-&gt;getRoundedInnerBorderFor(outerRect,
</span><span class="cx">                 outerBorderTopWidth, outerBorderBottomWidth, outerBorderLeftWidth, outerBorderRightWidth,
</span><span class="cx">                 includeLogicalLeftEdge, includeLogicalRightEdge);
</span><del>-            graphicsContext-&gt;clipOutRoundedRect(outerClip);
</del><ins>+            graphicsContext-&gt;clipOutRoundedRect(FloatRoundedRect(outerClip));
</ins><span class="cx">             drawBoxSideFromPath(graphicsContext, borderRect, borderPath, edges, thickness, drawThickness, side, style, color, SOLID, bleedAvoidance, includeLogicalLeftEdge, includeLogicalRightEdge);
</span><span class="cx">         }
</span><span class="cx">         return;
</span><span class="lines">@@ -2104,7 +2105,7 @@
</span><span class="cx">             topWidth, bottomWidth, leftWidth, rightWidth,
</span><span class="cx">             includeLogicalLeftEdge, includeLogicalRightEdge);
</span><span class="cx"> 
</span><del>-        graphicsContext-&gt;clipRoundedRect(clipRect);
</del><ins>+        graphicsContext-&gt;clipRoundedRect(FloatRoundedRect(clipRect));
</ins><span class="cx">         drawBoxSideFromPath(graphicsContext, borderRect, borderPath, edges, thickness, drawThickness, side, style, color, s2, bleedAvoidance, includeLogicalLeftEdge, includeLogicalRightEdge);
</span><span class="cx">         return;
</span><span class="cx">     }
</span><span class="lines">@@ -2353,7 +2354,7 @@
</span><span class="cx">     BoxSide side, const class BorderEdge edges[])
</span><span class="cx"> {
</span><span class="cx">     graphicsContext-&gt;clip(calculateSideRectIncludingInner(outerBorder, edges, side));
</span><del>-    graphicsContext-&gt;clipOutRoundedRect(calculateAdjustedInnerBorder(innerBorder, side));
</del><ins>+    graphicsContext-&gt;clipOutRoundedRect(FloatRoundedRect(calculateAdjustedInnerBorder(innerBorder, side)));
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void RenderBoxModelObject::getBorderEdgeInfo(BorderEdge edges[], const RenderStyle* style, bool includeLogicalLeftEdge, bool includeLogicalRightEdge) const
</span><span class="lines">@@ -2552,7 +2553,7 @@
</span><span class="cx">                 }
</span><span class="cx"> 
</span><span class="cx">                 if (!rectToClipOut.isEmpty())
</span><del>-                    context-&gt;clipOutRoundedRect(rectToClipOut);
</del><ins>+                    context-&gt;clipOutRoundedRect(FloatRoundedRect(rectToClipOut));
</ins><span class="cx"> 
</span><span class="cx">                 RoundedRect influenceRect(shadowRect, border.radii());
</span><span class="cx">                 influenceRect.expandRadii(2 * shadowPaintingExtent + shadowSpread);
</span><span class="lines">@@ -2562,7 +2563,7 @@
</span><span class="cx">                     fillRect.expandRadii(shadowSpread);
</span><span class="cx">                     if (!fillRect.isRenderable())
</span><span class="cx">                         fillRect.adjustRadii();
</span><del>-                    context-&gt;fillRoundedRect(fillRect, Color::black, s-&gt;colorSpace());
</del><ins>+                    context-&gt;fillRoundedRect(FloatRoundedRect(fillRect), Color::black, s-&gt;colorSpace());
</ins><span class="cx">                 }
</span><span class="cx">             } else {
</span><span class="cx">                 LayoutRect rectToClipOut = border.rect();
</span><span class="lines">@@ -2590,7 +2591,7 @@
</span><span class="cx"> 
</span><span class="cx">             if (holeRect.isEmpty()) {
</span><span class="cx">                 if (hasBorderRadius)
</span><del>-                    context-&gt;fillRoundedRect(border, shadowColor, s-&gt;colorSpace());
</del><ins>+                    context-&gt;fillRoundedRect(FloatRoundedRect(border), shadowColor, s-&gt;colorSpace());
</ins><span class="cx">                 else
</span><span class="cx">                     context-&gt;fillRect(border.rect(), shadowColor, s-&gt;colorSpace());
</span><span class="cx">                 continue;
</span><span class="lines">@@ -2635,7 +2636,7 @@
</span><span class="cx">             else
</span><span class="cx">                 context-&gt;setShadow(shadowOffset, shadowRadius, shadowColor, s-&gt;colorSpace());
</span><span class="cx"> 
</span><del>-            context-&gt;fillRectWithRoundedHole(outerRect, roundedHole, fillColor, s-&gt;colorSpace());
</del><ins>+            context-&gt;fillRectWithRoundedHole(outerRect, FloatRoundedRect(roundedHole), fillColor, s-&gt;colorSpace());
</ins><span class="cx">         }
</span><span class="cx">     }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderLayercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderLayer.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderLayer.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/RenderLayer.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -55,6 +55,7 @@
</span><span class="cx"> #include &quot;FloatConversion.h&quot;
</span><span class="cx"> #include &quot;FloatPoint3D.h&quot;
</span><span class="cx"> #include &quot;FloatRect.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;FlowThreadController.h&quot;
</span><span class="cx"> #include &quot;FocusController.h&quot;
</span><span class="cx"> #include &quot;Frame.h&quot;
</span><span class="lines">@@ -3615,7 +3616,7 @@
</span><span class="cx">         if (layer-&gt;renderer().hasOverflowClip() &amp;&amp; layer-&gt;renderer().style().hasBorderRadius() &amp;&amp; inContainingBlockChain(this, layer)) {
</span><span class="cx">                 LayoutPoint delta;
</span><span class="cx">                 layer-&gt;convertToLayerCoords(rootLayer, delta);
</span><del>-                context-&gt;clipRoundedRect(layer-&gt;renderer().style().getRoundedInnerBorderFor(LayoutRect(delta, layer-&gt;size())));
</del><ins>+                context-&gt;clipRoundedRect(FloatRoundedRect(layer-&gt;renderer().style().getRoundedInnerBorderFor(LayoutRect(delta, layer-&gt;size()))));
</ins><span class="cx">         }
</span><span class="cx"> 
</span><span class="cx">         if (layer == rootLayer)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderThemeIOSmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderThemeIOS.mm (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderThemeIOS.mm        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/RenderThemeIOS.mm        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -31,6 +31,7 @@
</span><span class="cx"> #import &quot;CSSValueKeywords.h&quot;
</span><span class="cx"> #import &quot;DateComponents.h&quot;
</span><span class="cx"> #import &quot;Document.h&quot;
</span><ins>+#import &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #import &quot;Font.h&quot;
</span><span class="cx"> #import &quot;FontCache.h&quot;
</span><span class="cx"> #import &quot;Frame.h&quot;
</span><span class="lines">@@ -450,7 +451,7 @@
</span><span class="cx">         paintInfo.context-&gt;drawRaisedEllipse(clip, Color::white, ColorSpaceDeviceRGB, shadowColor(), ColorSpaceDeviceRGB);
</span><span class="cx"> 
</span><span class="cx">         FloatSize radius(clip.width() / 2.0f, clip.height() / 2.0f);
</span><del>-        paintInfo.context-&gt;clipRoundedRect(clip, radius, radius, radius, radius);
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(clip, radius, radius, radius, radius));
</ins><span class="cx">     }
</span><span class="cx">     FloatPoint bottomCenter(clip.x() + clip.width() / 2.0, clip.maxY());
</span><span class="cx">     drawAxialGradient(cgContext, gradientWithName(ShadeGradient), clip.location(), FloatPoint(clip.x(), clip.maxY()), LinearInterpolation);
</span><span class="lines">@@ -465,7 +466,7 @@
</span><span class="cx"> 
</span><span class="cx">     GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx"> 
</span><del>-    paintInfo.context-&gt;clipRoundedRect(style.getRoundedBorderFor(rect));
</del><ins>+    paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(style.getRoundedBorderFor(rect)));
</ins><span class="cx"> 
</span><span class="cx">     // This gradient gets drawn black when printing.
</span><span class="cx">     // Do not draw the gradient if there is no visible top border.
</span><span class="lines">@@ -585,9 +586,9 @@
</span><span class="cx"> 
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx"> 
</span><del>-        paintInfo.context-&gt;clipRoundedRect(titleClip, 
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(titleClip,
</ins><span class="cx">             FloatSize(valueForLength(style.borderTopLeftRadius().width(), rect.width()) - style.borderLeftWidth(), valueForLength(style.borderTopLeftRadius().height(), rect.height()) - style.borderTopWidth()), FloatSize(0, 0),
</span><del>-            FloatSize(valueForLength(style.borderBottomLeftRadius().width(), rect.width()) - style.borderLeftWidth(), valueForLength(style.borderBottomLeftRadius().height(), rect.height()) - style.borderBottomWidth()), FloatSize(0, 0));
</del><ins>+            FloatSize(valueForLength(style.borderBottomLeftRadius().width(), rect.width()) - style.borderLeftWidth(), valueForLength(style.borderBottomLeftRadius().height(), rect.height()) - style.borderBottomWidth()), FloatSize(0, 0)));
</ins><span class="cx"> 
</span><span class="cx">         drawAxialGradient(cgContext, gradientWithName(ShadeGradient), titleClip.location(), FloatPoint(titleClip.x(), titleClip.maxY()), LinearInterpolation);
</span><span class="cx">         drawAxialGradient(cgContext, gradientWithName(ShineGradient), FloatPoint(titleClip.x(), titleClip.maxY()), titleClip.location(), ExponentialInterpolation);
</span><span class="lines">@@ -605,9 +606,9 @@
</span><span class="cx">     {
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx"> 
</span><del>-        paintInfo.context-&gt;clipRoundedRect(buttonClip, 
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(buttonClip,
</ins><span class="cx">             FloatSize(0, 0), FloatSize(valueForLength(style.borderTopRightRadius().width(), rect.width()) - style.borderRightWidth(), valueForLength(style.borderTopRightRadius().height(), rect.height()) - style.borderTopWidth()),
</span><del>-            FloatSize(0, 0), FloatSize(valueForLength(style.borderBottomRightRadius().width(), rect.width()) - style.borderRightWidth(), valueForLength(style.borderBottomRightRadius().height(), rect.height()) - style.borderBottomWidth()));
</del><ins>+            FloatSize(0, 0), FloatSize(valueForLength(style.borderBottomRightRadius().width(), rect.width()) - style.borderRightWidth(), valueForLength(style.borderBottomRightRadius().height(), rect.height()) - style.borderBottomWidth())));
</ins><span class="cx"> 
</span><span class="cx">         paintInfo.context-&gt;fillRect(buttonClip, style.visitedDependentColor(CSSPropertyBorderTopColor), style.colorSpace());
</span><span class="cx"> 
</span><span class="lines">@@ -716,7 +717,7 @@
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx"> 
</span><span class="cx">         IntSize cornerSize(cornerWidth, cornerHeight);
</span><del>-        RoundedRect innerBorder(trackClip, cornerSize, cornerSize, cornerSize, cornerSize);
</del><ins>+        FloatRoundedRect innerBorder(trackClip, cornerSize, cornerSize, cornerSize, cornerSize);
</ins><span class="cx">         paintInfo.context-&gt;clipRoundedRect(innerBorder);
</span><span class="cx"> 
</span><span class="cx">         CGContextRef cgContext = paintInfo.context-&gt;platformContext();
</span><span class="lines">@@ -832,7 +833,7 @@
</span><span class="cx"> 
</span><span class="cx">     // 1.2) Draw top gradient on the upper half. It is supposed to overlay the fill from the background and darker the stroked path.
</span><span class="cx">     FloatRect border(rect.x(), rect.y() + verticalOffset, rect.width(), progressBarHeight);
</span><del>-    paintInfo.context-&gt;clipRoundedRect(border, roundedCornerRadius, roundedCornerRadius, roundedCornerRadius, roundedCornerRadius);
</del><ins>+    paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(border, roundedCornerRadius, roundedCornerRadius, roundedCornerRadius, roundedCornerRadius));
</ins><span class="cx"> 
</span><span class="cx">     float upperGradientHeight = progressBarHeight / 2.;
</span><span class="cx">     RefPtr&lt;Gradient&gt; upperGradient = Gradient::create(FloatPoint(rect.x(), verticalRenderingPosition + 0.5), FloatPoint(rect.x(), verticalRenderingPosition + upperGradientHeight - 1.5));
</span><span class="lines">@@ -986,7 +987,7 @@
</span><span class="cx"> 
</span><span class="cx">         // Background picture frame and simple background icon with a gradient matching the button.
</span><span class="cx">         Color backgroundImageColor = buttonRenderer ? Color(buttonRenderer-&gt;style().visitedDependentColor(CSSPropertyBackgroundColor).rgb()) : Color(206.0f, 206.0f, 206.0f);
</span><del>-        paintInfo.context-&gt;fillRoundedRect(thumbnailPictureFrameRect, cornerSize, cornerSize, cornerSize, cornerSize, pictureFrameColor, ColorSpaceDeviceRGB);
</del><ins>+        paintInfo.context-&gt;fillRoundedRect(FloatRoundedRect(thumbnailPictureFrameRect, cornerSize, cornerSize, cornerSize, cornerSize), pictureFrameColor, ColorSpaceDeviceRGB);
</ins><span class="cx">         paintInfo.context-&gt;fillRect(thumbnailRect, backgroundImageColor, ColorSpaceDeviceRGB);
</span><span class="cx">         {
</span><span class="cx">             GraphicsContextStateSaver stateSaver2(*paintInfo.context);
</span><span class="lines">@@ -1007,7 +1008,7 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     // Foreground picture frame and icon.
</span><del>-    paintInfo.context-&gt;fillRoundedRect(thumbnailPictureFrameRect, cornerSize, cornerSize, cornerSize, cornerSize, pictureFrameColor, ColorSpaceDeviceRGB);
</del><ins>+    paintInfo.context-&gt;fillRoundedRect(FloatRoundedRect(thumbnailPictureFrameRect, cornerSize, cornerSize, cornerSize), cornerSize, pictureFrameColor, ColorSpaceDeviceRGB);
</ins><span class="cx">     icon-&gt;paint(paintInfo.context, thumbnailRect);
</span><span class="cx"> 
</span><span class="cx">     return false;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderThemeMacmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderThemeMac.mm (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderThemeMac.mm        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/RenderThemeMac.mm        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -29,6 +29,7 @@
</span><span class="cx"> #import &quot;Element.h&quot;
</span><span class="cx"> #import &quot;ExceptionCodePlaceholder.h&quot;
</span><span class="cx"> #import &quot;FileList.h&quot;
</span><ins>+#import &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #import &quot;Frame.h&quot;
</span><span class="cx"> #import &quot;FrameView.h&quot;
</span><span class="cx"> #import &quot;GraphicsContextCG.h&quot;
</span><span class="lines">@@ -1143,7 +1144,7 @@
</span><span class="cx"> 
</span><span class="cx">     GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx"> 
</span><del>-    RoundedRect border = o-&gt;style().getRoundedBorderFor(r, &amp;o-&gt;view());
</del><ins>+    FloatRoundedRect border = FloatRoundedRect(o-&gt;style().getRoundedBorderFor(r, &amp;o-&gt;view()));
</ins><span class="cx">     int radius = border.radii().topLeft().width();
</span><span class="cx"> 
</span><span class="cx">     CGColorSpaceRef cspace = deviceRGBColorSpaceRef();
</span><span class="lines">@@ -1177,7 +1178,7 @@
</span><span class="cx">     {
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx">         CGContextClipToRect(context, topGradient);
</span><del>-        paintInfo.context-&gt;clipRoundedRect(RoundedRect(enclosingIntRect(topGradient), border.radii().topLeft(), border.radii().topRight(), IntSize(), IntSize()));
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(enclosingIntRect(topGradient), border.radii().topLeft(), border.radii().topRight(), IntSize(), IntSize()));
</ins><span class="cx">         context = cgContextContainer.context();
</span><span class="cx">         CGContextDrawShading(context, topShading.get());
</span><span class="cx">     }
</span><span class="lines">@@ -1185,7 +1186,7 @@
</span><span class="cx">     if (!bottomGradient.isEmpty()) {
</span><span class="cx">         GraphicsContextStateSaver stateSaver(*paintInfo.context);
</span><span class="cx">         CGContextClipToRect(context, bottomGradient);
</span><del>-        paintInfo.context-&gt;clipRoundedRect(RoundedRect(enclosingIntRect(bottomGradient), IntSize(), IntSize(), border.radii().bottomLeft(), border.radii().bottomRight()));
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(enclosingIntRect(bottomGradient), IntSize(), IntSize(), border.radii().bottomLeft(), border.radii().bottomRight()));
</ins><span class="cx">         context = cgContextContainer.context();
</span><span class="cx">         CGContextDrawShading(context, bottomShading.get());
</span><span class="cx">     }
</span><span class="lines">@@ -1414,7 +1415,7 @@
</span><span class="cx">         mainShading = adoptCF(CGShadingCreateAxial(cspace, CGPointMake(bounds.x(),  bounds.y()), CGPointMake(bounds.x(), bounds.maxY()), mainFunction.get(), false, false));
</span><span class="cx"> 
</span><span class="cx">     IntSize radius(trackRadius, trackRadius);
</span><del>-    paintInfo.context-&gt;clipRoundedRect(RoundedRect(bounds, radius, radius, radius, radius));
</del><ins>+    paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(bounds, radius, radius, radius, radius));
</ins><span class="cx">     context = localContext.cgContext();
</span><span class="cx">     CGContextDrawShading(context, mainShading.get());
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderThemeSafaricpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderThemeSafari.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderThemeSafari.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/RenderThemeSafari.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -30,6 +30,7 @@
</span><span class="cx"> #include &quot;CSSValueKeywords.h&quot;
</span><span class="cx"> #include &quot;Document.h&quot;
</span><span class="cx"> #include &quot;Element.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;Frame.h&quot;
</span><span class="cx"> #include &quot;FrameView.h&quot;
</span><span class="cx"> #include &quot;GraphicsContextCG.h&quot;
</span><span class="lines">@@ -755,7 +756,7 @@
</span><span class="cx"> 
</span><span class="cx">     paintInfo.context-&gt;save();
</span><span class="cx"> 
</span><del>-    RoundedRect bound = o-&gt;style().getRoundedBorderFor(r);
</del><ins>+    FloatRoundedRect bound = FloatRoundedRect(o-&gt;style().getRoundedBorderFor(r));
</ins><span class="cx">     int radius = bound.radii().topLeft().width();
</span><span class="cx"> 
</span><span class="cx">     CGColorSpaceRef cspace = deviceRGBColorSpaceRef();
</span><span class="lines">@@ -785,14 +786,14 @@
</span><span class="cx"> 
</span><span class="cx">     paintInfo.context-&gt;save();
</span><span class="cx">     CGContextClipToRect(context, topGradient);
</span><del>-    paintInfo.context-&gt;clipRoundedRect(RoundedRect(enclosingIntRect(topGradient), bound.radii().topLeft(), bound.radii().topRight(), IntSize(), IntSize()));
</del><ins>+    paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(enclosingIntRect(topGradient), bound.radii().topLeft(), bound.radii().topRight(), IntSize(), IntSize()));
</ins><span class="cx">     CGContextDrawShading(context, topShading.get());
</span><span class="cx">     paintInfo.context-&gt;restore();
</span><span class="cx"> 
</span><span class="cx">     if (!bottomGradient.isEmpty()) {
</span><span class="cx">         paintInfo.context-&gt;save();
</span><span class="cx">         CGContextClipToRect(context, bottomGradient);
</span><del>-        paintInfo.context-&gt;clipRoundedRect(RoundedRect(enclosingIntRect(bottomGradient), IntSize(), IntSize(), bound.radii().bottomLeft(), bound.radii().bottomRight()));
</del><ins>+        paintInfo.context-&gt;clipRoundedRect(FloatRoundedRect(enclosingIntRect(bottomGradient), IntSize(), IntSize(), bound.radii().bottomLeft(), bound.radii().bottomRight()));
</ins><span class="cx">         CGContextDrawShading(context, bottomShading.get());
</span><span class="cx">         paintInfo.context-&gt;restore();
</span><span class="cx">     }
</span><span class="lines">@@ -956,7 +957,7 @@
</span><span class="cx"> bool RenderThemeSafari::paintSliderTrack(RenderObject* o, const PaintInfo&amp; paintInfo, const IntRect&amp; r)
</span><span class="cx"> {
</span><span class="cx">     IntSize radius(trackRadius, trackRadius);
</span><del>-    RoundedRect bounds(r, radius, radius, radius, radius);
</del><ins>+    FloatRoundedRect bounds(r, radius, radius, radius, radius);
</ins><span class="cx"> 
</span><span class="cx">     if (o-&gt;style().appearance() ==  SliderHorizontalPart)
</span><span class="cx">         bounds.setRect(IntRect(r.x(),
</span><span class="lines">@@ -973,7 +974,7 @@
</span><span class="cx">     CGColorSpaceRef cspace = deviceRGBColorSpaceRef();
</span><span class="cx"> 
</span><span class="cx">     paintInfo.context-&gt;save();
</span><del>-    CGContextClipToRect(context, pixelSnappedIntRect(bounds.rect()));
</del><ins>+    CGContextClipToRect(context, bounds.rect());
</ins><span class="cx"> 
</span><span class="cx">     struct CGFunctionCallbacks mainCallbacks = { 0, TrackGradientInterpolate, NULL };
</span><span class="cx">     RetainPtr&lt;CGFunctionRef&gt; mainFunction = adoptCF(CGFunctionCreate(NULL, 1, NULL, 4, NULL, &amp;mainCallbacks));
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingshapesBoxShapecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/shapes/BoxShape.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/shapes/BoxShape.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/shapes/BoxShape.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -156,18 +156,11 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static void addRoundedRect(Path&amp; path, const FloatRect&amp; rect, const FloatRoundedRect::Radii&amp; radii)
-{
-    path.addRoundedRect(rect, radii.topLeft(), radii.topRight(), radii.bottomLeft(), radii.bottomRight(), Path::PreferBezierRoundedRect);
-}
-
</del><span class="cx"> void BoxShape::buildDisplayPaths(DisplayPaths&amp; paths) const
</span><span class="cx"> {
</span><del>-    addRoundedRect(paths.shape, m_bounds.rect(), m_bounds.radii());
-    if (shapeMargin()) {
-        const FloatRoundedRect&amp; marginBounds = shapeMarginBounds();
-        addRoundedRect(paths.marginShape, marginBounds.rect(), marginBounds.radii());
-    }
</del><ins>+    paths.shape.addRoundedRect(m_bounds, Path::PreferBezierRoundedRect);
+    if (shapeMargin())
+        paths.marginShape.addRoundedRect(shapeMarginBounds(), Path::PreferBezierRoundedRect);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingstyleBasicShapescpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/style/BasicShapes.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/style/BasicShapes.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebCore/rendering/style/BasicShapes.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -34,6 +34,7 @@
</span><span class="cx"> #include &quot;BasicShapeFunctions.h&quot;
</span><span class="cx"> #include &quot;CalculationValue.h&quot;
</span><span class="cx"> #include &quot;FloatRect.h&quot;
</span><ins>+#include &quot;FloatRoundedRect.h&quot;
</ins><span class="cx"> #include &quot;LengthFunctions.h&quot;
</span><span class="cx"> #include &quot;Path.h&quot;
</span><span class="cx"> #include &quot;RenderBox.h&quot;
</span><span class="lines">@@ -355,7 +356,7 @@
</span><span class="cx">     ASSERT(path.isEmpty());
</span><span class="cx">     float left = floatValueForLength(m_left, boundingBox.width());
</span><span class="cx">     float top = floatValueForLength(m_top, boundingBox.height());
</span><del>-    path.addRoundedRect(
</del><ins>+    FloatRoundedRect r = FloatRoundedRect(
</ins><span class="cx">         FloatRect(
</span><span class="cx">             left + boundingBox.x(),
</span><span class="cx">             top + boundingBox.y(),
</span><span class="lines">@@ -367,6 +368,7 @@
</span><span class="cx">         floatSizeForLengthSize(m_bottomLeftRadius, boundingBox),
</span><span class="cx">         floatSizeForLengthSize(m_bottomRightRadius, boundingBox)
</span><span class="cx">     );
</span><ins>+    path.addRoundedRect(r);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> PassRefPtr&lt;BasicShape&gt; BasicShapeInset::blend(const BasicShape* other, double progress) const
</span></span></pre></div>
<a id="trunkSourceWebKitwinChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/ChangeLog (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/ChangeLog        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebKit/win/ChangeLog        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -1,3 +1,19 @@
</span><ins>+2014-03-04  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+        Subpixel rendering: Make GraphicsLayer::fillRect FloatRoundedRect based and cleanup dependencies.
+        https://bugs.webkit.org/show_bug.cgi?id=129557
+
+        Reviewed by Simon Fraser.
+
+        This is the preparation for snapping rounded rects to device pixel position. It enables
+        device pixel aware border-radius painting.
+
+        No change in functionality.
+
+        * FullscreenVideoController.cpp:
+        (HUDSlider::draw):
+        (FullscreenVideoController::draw):
+
</ins><span class="cx"> 2014-03-02  Darin Adler  &lt;darin@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Streamline use of TextIterator, cutting down includes and use of soon-to-be-deleted functions
</span></span></pre></div>
<a id="trunkSourceWebKitwinFullscreenVideoControllercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/FullscreenVideoController.cpp (165054 => 165055)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/FullscreenVideoController.cpp        2014-03-04 17:05:26 UTC (rev 165054)
+++ trunk/Source/WebKit/win/FullscreenVideoController.cpp        2014-03-04 17:06:50 UTC (rev 165055)
</span><span class="lines">@@ -34,6 +34,7 @@
</span><span class="cx"> #include &lt;ApplicationServices/ApplicationServices.h&gt;
</span><span class="cx"> #include &lt;WebCore/BitmapInfo.h&gt;
</span><span class="cx"> #include &lt;WebCore/Chrome.h&gt;
</span><ins>+#include &lt;WebCore/FloatRoundedRect.h&gt;
</ins><span class="cx"> #include &lt;WebCore/Font.h&gt;
</span><span class="cx"> #include &lt;WebCore/FontSelector.h&gt;
</span><span class="cx"> #include &lt;WebCore/GraphicsContext.h&gt;
</span><span class="lines">@@ -135,7 +136,7 @@
</span><span class="cx"> {
</span><span class="cx">     // Draw gutter
</span><span class="cx">     IntSize radius(m_rect.height() / 2, m_rect.height() / 2);
</span><del>-    context.fillRoundedRect(m_rect, radius, radius, radius, radius, Color(sliderGutterColor), ColorSpaceDeviceRGB);
</del><ins>+    context.fillRoundedRect(FloatRoundedRect(m_rect, radius, radius, radius, radius), Color(sliderGutterColor), ColorSpaceDeviceRGB);
</ins><span class="cx"> 
</span><span class="cx">     // Draw button
</span><span class="cx">     context.setStrokeColor(Color(sliderButtonColor), ColorSpaceDeviceRGB);
</span><span class="lines">@@ -491,9 +492,9 @@
</span><span class="cx">     IntSize innerRadius(borderRadius - borderThickness, borderRadius - borderThickness);
</span><span class="cx">     IntRect innerRect(borderThickness, borderThickness, windowWidth - borderThickness * 2, windowHeight - borderThickness * 2);
</span><span class="cx"> 
</span><del>-    context.fillRoundedRect(outerRect, outerRadius, outerRadius, outerRadius, outerRadius, Color(borderColor), ColorSpaceDeviceRGB);
</del><ins>+    context.fillRoundedRect(FloatRoundedRect(outerRect, outerRadius, outerRadius, outerRadius, outerRadius), Color(borderColor), ColorSpaceDeviceRGB);
</ins><span class="cx">     context.setCompositeOperation(CompositeCopy);
</span><del>-    context.fillRoundedRect(innerRect, innerRadius, innerRadius, innerRadius, innerRadius, Color(backgroundColor), ColorSpaceDeviceRGB);
</del><ins>+    context.fillRoundedRect(FloatRoundedRect(innerRect, innerRadius, innerRadius, innerRadius, innerRadius), Color(backgroundColor), ColorSpaceDeviceRGB);
</ins><span class="cx"> 
</span><span class="cx">     // Draw the widgets
</span><span class="cx">     m_playPauseButton.draw(context);
</span></span></pre>
</div>
</div>

</body>
</html>