<!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>[129337] 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/129337">129337</a></dd>
<dt>Author</dt> <dd>yurys@chromium.org</dd>
<dt>Date</dt> <dd>2012-09-24 02:38:12 -0700 (Mon, 24 Sep 2012)</dd>
</dl>

<h3>Log Message</h3>
<pre>Unreviewed, rolling out <a href="http://trac.webkit.org/projects/webkit/changeset/122243">r122243</a>.
http://trac.webkit.org/changeset/129243
https://bugs.webkit.org/show_bug.cgi?id=97441

WebFilterOperationsTest.saveAndRestore added in the change is failing.

Source/Platform:

* chromium/public/WebFilterOperation.h:
(WebKit::WebFilterOperation::amount):
(WebKit::WebFilterOperation::dropShadowOffset):
(WebKit::WebFilterOperation::matrix):
(WebKit::WebFilterOperation::zoomRect):
(WebFilterOperation):

Source/WebKit/chromium:

* tests/FilterOperationsTest.cpp:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourcePlatformChangeLog">trunk/Source/Platform/ChangeLog</a></li>
<li><a href="#trunkSourcePlatformchromiumpublicWebFilterOperationh">trunk/Source/Platform/chromium/public/WebFilterOperation.h</a></li>
<li><a href="#trunkSourceWebKitchromiumChangeLog">trunk/Source/WebKit/chromium/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitchromiumtestsFilterOperationsTestcpp">trunk/Source/WebKit/chromium/tests/FilterOperationsTest.cpp</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourcePlatformChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/Platform/ChangeLog (129336 => 129337)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/Platform/ChangeLog        2012-09-24 09:23:20 UTC (rev 129336)
+++ trunk/Source/Platform/ChangeLog        2012-09-24 09:38:12 UTC (rev 129337)
</span><span class="lines">@@ -1,3 +1,18 @@
</span><ins>+2012-09-24  Yury Semikhatsky  &lt;yurys@chromium.org&gt;
+
+        Unreviewed, rolling out r122243.
+        http://trac.webkit.org/changeset/129243
+        https://bugs.webkit.org/show_bug.cgi?id=97441
+
+        WebFilterOperationsTest.saveAndRestore added in the change is failing.
+
+        * chromium/public/WebFilterOperation.h:
+        (WebKit::WebFilterOperation::amount):
+        (WebKit::WebFilterOperation::dropShadowOffset):
+        (WebKit::WebFilterOperation::matrix):
+        (WebKit::WebFilterOperation::zoomRect):
+        (WebFilterOperation):
+
</ins><span class="cx"> 2012-09-21  Alexandre Elias  &lt;aelias@chromium.org&gt;
</span><span class="cx"> 
</span><span class="cx">         [chromium] Forward-declare WebSize as a struct
</span></span></pre></div>
<a id="trunkSourcePlatformchromiumpublicWebFilterOperationh"></a>
<div class="modfile"><h4>Modified: trunk/Source/Platform/chromium/public/WebFilterOperation.h (129336 => 129337)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/Platform/chromium/public/WebFilterOperation.h        2012-09-24 09:23:20 UTC (rev 129336)
+++ trunk/Source/Platform/chromium/public/WebFilterOperation.h        2012-09-24 09:38:12 UTC (rev 129337)
</span><span class="lines">@@ -55,23 +55,12 @@
</span><span class="cx"> 
</span><span class="cx">     float amount() const
</span><span class="cx">     {
</span><del>-        WEBKIT_ASSERT(m_type == FilterTypeGrayscale
-                   || m_type == FilterTypeSepia
-                   || m_type == FilterTypeSaturate
-                   || m_type == FilterTypeHueRotate
-                   || m_type == FilterTypeInvert
-                   || m_type == FilterTypeBrightness
-                   || m_type == FilterTypeContrast
-                   || m_type == FilterTypeOpacity
-                   || m_type == FilterTypeBlur
-                   || m_type == FilterTypeDropShadow
-                   || m_type == FilterTypeZoom);
</del><span class="cx">         return m_amount;
</span><span class="cx">     }
</span><span class="cx">     WebPoint dropShadowOffset() const
</span><span class="cx">     {
</span><span class="cx">         WEBKIT_ASSERT(m_type == FilterTypeDropShadow);
</span><del>-        return m_dropShadowOffset;
</del><ins>+        return WebPoint(m_dropShadowOffset);
</ins><span class="cx">     }
</span><span class="cx">     WebColor dropShadowColor() const
</span><span class="cx">     {
</span><span class="lines">@@ -80,16 +69,16 @@
</span><span class="cx">     }
</span><span class="cx">     const SkScalar* matrix() const
</span><span class="cx">     {
</span><del>-        WEBKIT_ASSERT(m_type == FilterTypeColorMatrix);
</del><span class="cx">         return m_matrix;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     WebRect zoomRect() const
</span><span class="cx">     {
</span><span class="cx">         WEBKIT_ASSERT(m_type == FilterTypeZoom);
</span><del>-        return m_zoomRect;
</del><ins>+        return WebRect(m_zoomRect);
</ins><span class="cx">     }
</span><span class="cx"> 
</span><ins>+#define WEBKIT_HAS_NEW_WEBFILTEROPERATION_API 1
</ins><span class="cx">     static WebFilterOperation createGrayscaleFilter(float amount) { return WebFilterOperation(FilterTypeGrayscale, amount); }
</span><span class="cx">     static WebFilterOperation createSepiaFilter(float amount) { return WebFilterOperation(FilterTypeSepia, amount); }
</span><span class="cx">     static WebFilterOperation createSaturateFilter(float amount) { return WebFilterOperation(FilterTypeSaturate, amount); }
</span><span class="lines">@@ -105,46 +94,6 @@
</span><span class="cx"> 
</span><span class="cx">     bool equals(const WebFilterOperation&amp; other) const;
</span><span class="cx"> 
</span><del>-    // Methods for restoring a WebFilterOperation.
-    static WebFilterOperation createEmptyFilter() { return WebFilterOperation(FilterTypeGrayscale, 0.0); }
-    void setType(FilterType type) { m_type = type; }
-    void setAmount(float amount)
-    {
-        WEBKIT_ASSERT(m_type == FilterTypeGrayscale
-                   || m_type == FilterTypeSepia
-                   || m_type == FilterTypeSaturate
-                   || m_type == FilterTypeHueRotate
-                   || m_type == FilterTypeInvert
-                   || m_type == FilterTypeBrightness
-                   || m_type == FilterTypeContrast
-                   || m_type == FilterTypeOpacity
-                   || m_type == FilterTypeBlur
-                   || m_type == FilterTypeDropShadow
-                   || m_type == FilterTypeZoom);
-        m_amount = amount;
-    }
-    void setDropShadowOffset(WebPoint offset)
-    {
-        WEBKIT_ASSERT(m_type == FilterTypeDropShadow);
-        m_dropShadowOffset = offset;
-    }
-    void setDropShadowColor(WebColor color)
-    {
-        WEBKIT_ASSERT(m_type == FilterTypeDropShadow);
-        m_dropShadowColor = color;
-    }
-    void setMatrix(const SkScalar matrix[20])
-    {
-        WEBKIT_ASSERT(m_type == FilterTypeColorMatrix);
-        for (unsigned i = 0; i &lt; 20; ++i)
-            m_matrix[i] = matrix[i];
-    }
-    void setZoomRect(WebRect rect)
-    {
-        WEBKIT_ASSERT(m_type == FilterTypeZoom);
-        m_zoomRect = rect;
-    }
-
</del><span class="cx"> private:
</span><span class="cx">     FilterType m_type;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebKitchromiumChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/chromium/ChangeLog (129336 => 129337)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/chromium/ChangeLog        2012-09-24 09:23:20 UTC (rev 129336)
+++ trunk/Source/WebKit/chromium/ChangeLog        2012-09-24 09:38:12 UTC (rev 129337)
</span><span class="lines">@@ -1,3 +1,13 @@
</span><ins>+2012-09-24  Yury Semikhatsky  &lt;yurys@chromium.org&gt;
+
+        Unreviewed, rolling out r122243.
+        http://trac.webkit.org/changeset/129243
+        https://bugs.webkit.org/show_bug.cgi?id=97441
+
+        WebFilterOperationsTest.saveAndRestore added in the change is failing.
+
+        * tests/FilterOperationsTest.cpp:
+
</ins><span class="cx"> 2012-09-23  Keishi Hattori  &lt;keishi@webkit.org&gt;
</span><span class="cx"> 
</span><span class="cx">         Add suggestionPicker to CalendarPicker
</span></span></pre></div>
<a id="trunkSourceWebKitchromiumtestsFilterOperationsTestcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/chromium/tests/FilterOperationsTest.cpp (129336 => 129337)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/chromium/tests/FilterOperationsTest.cpp        2012-09-24 09:23:20 UTC (rev 129336)
+++ trunk/Source/WebKit/chromium/tests/FilterOperationsTest.cpp        2012-09-24 09:38:12 UTC (rev 129337)
</span><span class="lines">@@ -89,108 +89,5 @@
</span><span class="cx">     EXPECT_EQ(54, left);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-#define SAVE_RESTORE_AMOUNT(Type, a) \
-    { \
-        WebFilterOperation op = WebFilterOperation::create##Type##Filter(a); \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op.type()); \
-        EXPECT_EQ(a, op.amount()); \
-        \
-        WebFilterOperation op2 = WebFilterOperation::createEmptyFilter(); \
-        op2.setType(WebFilterOperation::FilterType##Type); \
-        \
-        EXPECT_NE(a, op2.amount()); \
-        \
-        op2.setAmount(a); \
-        \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op2.type()); \
-        EXPECT_EQ(a, op2.amount()); \
-    }
-
-#define SAVE_RESTORE_OFFSET_AMOUNT_COLOR(Type, a, b, c) \
-    { \
-        WebFilterOperation op = WebFilterOperation::create##Type##Filter(a, b, c); \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op.type()); \
-        EXPECT_EQ(a, op.dropShadowOffset()); \
-        EXPECT_EQ(b, op.amount()); \
-        EXPECT_EQ(c, op.dropShadowColor()); \
-        \
-        WebFilterOperation op2 = WebFilterOperation::createEmptyFilter(); \
-        op2.setType(WebFilterOperation::FilterType##Type); \
-        \
-        EXPECT_NE(a, op2.dropShadowOffset()); \
-        EXPECT_NE(b, op2.amount()); \
-        EXPECT_NE(c, op2.dropShadowColor()); \
-        \
-        op2.setDropShadowOffset(a); \
-        op2.setAmount(b); \
-        op2.setDropShadowColor(c); \
-        \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op2.type()); \
-        EXPECT_EQ(a, op2.dropShadowOffset()); \
-        EXPECT_EQ(b, op2.amount()); \
-        EXPECT_EQ(c, op2.dropShadowColor()); \
-    }
-
-#define SAVE_RESTORE_MATRIX(Type, a) \
-    { \
-        WebFilterOperation op = WebFilterOperation::create##Type##Filter(a); \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op.type());     \
-        for (unsigned i = 0; i &lt; 20; ++i) \
-            EXPECT_EQ(a[i], op.matrix()[i]); \
-        \
-        WebFilterOperation op2 = WebFilterOperation::createEmptyFilter(); \
-        op2.setType(WebFilterOperation::FilterType##Type); \
-        \
-        for (unsigned i = 0; i &lt; 20; ++i) \
-            EXPECT_NE(a[i], op2.matrix()[i]); \
-        \
-        op2.setMatrix(a); \
-        \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op2.type()); \
-        for (unsigned i = 0; i &lt; 20; ++i) \
-            EXPECT_EQ(a[i], op.matrix()[i]); \
-    }
-
-#define SAVE_RESTORE_ZOOMRECT_AMOUNT(Type, a, b) \
-    { \
-        WebFilterOperation op = WebFilterOperation::create##Type##Filter(a, b); \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op.type()); \
-        EXPECT_EQ(a, op.zoomRect()); \
-        EXPECT_EQ(b, op.amount()); \
-        \
-        WebFilterOperation op2 = WebFilterOperation::createEmptyFilter(); \
-        op2.setType(WebFilterOperation::FilterType##Type); \
-        \
-        EXPECT_NE(a, op2.zoomRect()); \
-        EXPECT_NE(b, op2.amount()); \
-        \
-        op2.setZoomRect(a); \
-        op2.setAmount(b); \
-        \
-        EXPECT_EQ(WebFilterOperation::FilterType##Type, op2.type()); \
-        EXPECT_EQ(a, op2.zoomRect()); \
-        EXPECT_EQ(b, op2.amount()); \
-    }
-
-
-TEST(WebFilterOperationsTest, saveAndRestore)
-{
-    SAVE_RESTORE_AMOUNT(Grayscale, 0.6f);
-    SAVE_RESTORE_AMOUNT(Sepia, 0.6f);
-    SAVE_RESTORE_AMOUNT(Saturate, 0.6f);
-    SAVE_RESTORE_AMOUNT(HueRotate, 0.6f);
-    SAVE_RESTORE_AMOUNT(Invert, 0.6f);
-    SAVE_RESTORE_AMOUNT(Brightness, 0.6f);
-    SAVE_RESTORE_AMOUNT(Contrast, 0.6f);
-    SAVE_RESTORE_AMOUNT(Opacity, 0.6f);
-    SAVE_RESTORE_AMOUNT(Blur, 0.6f);
-    SAVE_RESTORE_OFFSET_AMOUNT_COLOR(DropShadow, WebPoint(3, 4), 0.4f, 0xffffff00);
-
-    SkScalar matrix[20] = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19 };
-    SAVE_RESTORE_MATRIX(ColorMatrix, matrix);
-
-    SAVE_RESTORE_ZOOMRECT_AMOUNT(Zoom, WebRect(20, 19, 18, 17), 32);
</del><span class="cx"> }
</span><span class="cx"> 
</span><del>-}
-
</del></span></pre>
</div>
</div>

</body>
</html>