<!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>[164501] trunk/Source/WebCore</title>
</head>
<body>

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

<h3>Log Message</h3>
<pre>Disallow the use of -webkit-user-modify on shadow pseudo elements
https://bugs.webkit.org/show_bug.cgi?id=129144

Reviewed by Geoffrey Garen.

Completely disallow -webkit-user-modify on user agent (builtin) pseudo elements.

We've already had rules to do this in html.css but just hard code it into the engine
in order to eliminate the all uses of -webkit-user-modify in html.css.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::adjustRenderStyle):
* css/html.css:
(input::-webkit-textfield-decoration-container):
(input::-webkit-clear-button):
(input[type=&quot;search&quot;]::-webkit-search-cancel-button):
(input[type=&quot;search&quot;]::-webkit-search-decoration):
(input[type=&quot;search&quot;]::-webkit-search-results-decoration):
(input[type=&quot;search&quot;]::-webkit-search-results-button):
(input::-webkit-inner-spin-button):
(input::-webkit-input-speech-button):
(input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
(input[type=&quot;file&quot;]::-webkit-file-upload-button):
(input[type=&quot;range&quot;]::-webkit-slider-container, input[type=&quot;range&quot;]::-webkit-media-slider-container):
(input[type=&quot;range&quot;]::-webkit-slider-runnable-track):
(input[type=&quot;range&quot;]::-webkit-slider-thumb, input[type=&quot;range&quot;]::-webkit-media-slider-thumb):
(input[type=&quot;color&quot;]::-webkit-color-swatch-wrapper):
(input[type=&quot;color&quot;]::-webkit-color-swatch):
(::-webkit-validation-bubble):
(::-webkit-validation-bubble-message):
(::-webkit-validation-bubble-text-block):
(::-webkit-validation-bubble-heading):
(::-webkit-validation-bubble-arrow):
(::-webkit-validation-bubble-arrow-clipper):
(meter::-webkit-meter-inner-element):
(meter::-webkit-meter-bar):
(meter::-webkit-meter-optimum-value):
(meter::-webkit-meter-suboptimum-value):
(meter::-webkit-meter-even-less-good-value):
(progress::-webkit-progress-inner-element):
(progress::-webkit-progress-bar):
(progress::-webkit-progress-value):</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorecssStyleResolvercpp">trunk/Source/WebCore/css/StyleResolver.cpp</a></li>
<li><a href="#trunkSourceWebCorecsshtmlcss">trunk/Source/WebCore/css/html.css</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (164500 => 164501)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-02-21 22:27:27 UTC (rev 164500)
+++ trunk/Source/WebCore/ChangeLog        2014-02-21 22:33:14 UTC (rev 164501)
</span><span class="lines">@@ -1,3 +1,48 @@
</span><ins>+2014-02-21  Ryosuke Niwa  &lt;rniwa@webkit.org&gt;
+
+        Disallow the use of -webkit-user-modify on shadow pseudo elements
+        https://bugs.webkit.org/show_bug.cgi?id=129144
+
+        Reviewed by Geoffrey Garen.
+
+        Completely disallow -webkit-user-modify on user agent (builtin) pseudo elements.
+
+        We've already had rules to do this in html.css but just hard code it into the engine
+        in order to eliminate the all uses of -webkit-user-modify in html.css.
+
+        * css/StyleResolver.cpp:
+        (WebCore::StyleResolver::adjustRenderStyle):
+        * css/html.css:
+        (input::-webkit-textfield-decoration-container):
+        (input::-webkit-clear-button):
+        (input[type=&quot;search&quot;]::-webkit-search-cancel-button):
+        (input[type=&quot;search&quot;]::-webkit-search-decoration):
+        (input[type=&quot;search&quot;]::-webkit-search-results-decoration):
+        (input[type=&quot;search&quot;]::-webkit-search-results-button):
+        (input::-webkit-inner-spin-button):
+        (input::-webkit-input-speech-button):
+        (input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
+        (input[type=&quot;file&quot;]::-webkit-file-upload-button):
+        (input[type=&quot;range&quot;]::-webkit-slider-container, input[type=&quot;range&quot;]::-webkit-media-slider-container):
+        (input[type=&quot;range&quot;]::-webkit-slider-runnable-track):
+        (input[type=&quot;range&quot;]::-webkit-slider-thumb, input[type=&quot;range&quot;]::-webkit-media-slider-thumb):
+        (input[type=&quot;color&quot;]::-webkit-color-swatch-wrapper):
+        (input[type=&quot;color&quot;]::-webkit-color-swatch):
+        (::-webkit-validation-bubble):
+        (::-webkit-validation-bubble-message):
+        (::-webkit-validation-bubble-text-block):
+        (::-webkit-validation-bubble-heading):
+        (::-webkit-validation-bubble-arrow):
+        (::-webkit-validation-bubble-arrow-clipper):
+        (meter::-webkit-meter-inner-element):
+        (meter::-webkit-meter-bar):
+        (meter::-webkit-meter-optimum-value):
+        (meter::-webkit-meter-suboptimum-value):
+        (meter::-webkit-meter-even-less-good-value):
+        (progress::-webkit-progress-inner-element):
+        (progress::-webkit-progress-bar):
+        (progress::-webkit-progress-value):
+
</ins><span class="cx"> 2014-02-21  Eric Carlson  &lt;eric.carlson@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Fix TimeRanges layering violations
</span></span></pre></div>
<a id="trunkSourceWebCorecssStyleResolvercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/StyleResolver.cpp (164500 => 164501)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/StyleResolver.cpp        2014-02-21 22:27:27 UTC (rev 164500)
+++ trunk/Source/WebCore/css/StyleResolver.cpp        2014-02-21 22:33:14 UTC (rev 164501)
</span><span class="lines">@@ -1250,6 +1250,10 @@
</span><span class="cx">         style.setOverflowY(style.overflowY() == OVISIBLE ? OAUTO : style.overflowY());
</span><span class="cx">     }
</span><span class="cx"> 
</span><ins>+    // Disallow -webkit-user-modify on :pseudo and ::pseudo elements.
+    if (e &amp;&amp; !e-&gt;shadowPseudoId().isNull())
+        style.setUserModify(READ_ONLY);
+
</ins><span class="cx">     if (doesNotInheritTextDecoration(style, e))
</span><span class="cx">         style.setTextDecorationsInEffect(style.textDecoration());
</span><span class="cx">     else
</span></span></pre></div>
<a id="trunkSourceWebCorecsshtmlcss"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/html.css (164500 => 164501)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/html.css        2014-02-21 22:27:27 UTC (rev 164500)
+++ trunk/Source/WebCore/css/html.css        2014-02-21 22:33:14 UTC (rev 164501)
</span><span class="lines">@@ -447,7 +447,6 @@
</span><span class="cx"> input::-webkit-textfield-decoration-container {
</span><span class="cx">     display: -webkit-flex;
</span><span class="cx">     -webkit-align-items: center;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     content: none !important;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -459,7 +458,6 @@
</span><span class="cx">     -webkit-appearance: searchfield-cancel-button;
</span><span class="cx">     display: inline-block;
</span><span class="cx">     -webkit-flex: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     margin-left: 2px;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -467,7 +465,6 @@
</span><span class="cx">     -webkit-appearance: searchfield-cancel-button;
</span><span class="cx">     display: block;
</span><span class="cx">     -webkit-flex: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     -webkit-align-self: flex-start;
</span><span class="cx">     margin: auto 0;
</span><span class="cx"> }
</span><span class="lines">@@ -476,7 +473,6 @@
</span><span class="cx">     -webkit-appearance: searchfield-decoration;
</span><span class="cx">     display: block;
</span><span class="cx">     -webkit-flex: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     -webkit-align-self: flex-start;
</span><span class="cx">     margin: auto 0;
</span><span class="cx"> }
</span><span class="lines">@@ -485,7 +481,6 @@
</span><span class="cx">     -webkit-appearance: searchfield-results-decoration;
</span><span class="cx">     display: block;
</span><span class="cx">     -webkit-flex: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     -webkit-align-self: flex-start;
</span><span class="cx">     margin: auto 0;
</span><span class="cx"> }
</span><span class="lines">@@ -494,7 +489,6 @@
</span><span class="cx">     -webkit-appearance: searchfield-results-button;
</span><span class="cx">     display: block;
</span><span class="cx">     -webkit-flex: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if defined(ENABLE_DATALIST_ELEMENT) &amp;&amp; ENABLE_DATALIST_ELEMENT
</span><span class="lines">@@ -589,7 +583,6 @@
</span><span class="cx">     vertical-align: top;
</span><span class="cx">     -webkit-flex: none;
</span><span class="cx">     -webkit-user-select: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if defined(ENABLE_INPUT_SPEECH) &amp;&amp; ENABLE_INPUT_SPEECH
</span><span class="lines">@@ -598,7 +591,6 @@
</span><span class="cx">     display: block;
</span><span class="cx">     vertical-align: top;
</span><span class="cx">     -webkit-flex: none;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     -webkit-align-self: flex-start;
</span><span class="cx">     margin: auto 0;
</span><span class="cx"> }
</span><span class="lines">@@ -642,7 +634,6 @@
</span><span class="cx">     white-space: pre;
</span><span class="cx">     word-wrap: normal;
</span><span class="cx">     overflow: hidden;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> input[type=&quot;password&quot;] {
</span><span class="lines">@@ -691,7 +682,6 @@
</span><span class="cx"> 
</span><span class="cx"> input[type=&quot;file&quot;]::-webkit-file-upload-button {
</span><span class="cx">     -webkit-appearance: push-button;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     white-space: nowrap;
</span><span class="cx">     margin: 0;
</span><span class="cx">     font-size: inherit;
</span><span class="lines">@@ -727,7 +717,6 @@
</span><span class="cx"> input[type=&quot;range&quot;]::-webkit-slider-container, input[type=&quot;range&quot;]::-webkit-media-slider-container {
</span><span class="cx">     -webkit-flex: 1;
</span><span class="cx">     box-sizing: border-box;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     display: -webkit-flex;
</span><span class="cx">     -webkit-align-contents: center;
</span><span class="cx"> }
</span><span class="lines">@@ -737,14 +726,12 @@
</span><span class="cx">     -webkit-align-self: center;
</span><span class="cx"> 
</span><span class="cx">     box-sizing: border-box;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     display: block;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> input[type=&quot;range&quot;]::-webkit-slider-thumb, input[type=&quot;range&quot;]::-webkit-media-slider-thumb {
</span><span class="cx">     -webkit-appearance: sliderthumb-horizontal;
</span><span class="cx">     box-sizing: border-box;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     display: block;
</span><span class="cx"> #if defined(WTF_PLATFORM_IOS) &amp;&amp; WTF_PLATFORM_IOS
</span><span class="cx">     background-color: white;
</span><span class="lines">@@ -853,7 +840,6 @@
</span><span class="cx">     display:-webkit-flex;
</span><span class="cx">     padding: 4px 2px;
</span><span class="cx">     box-sizing: border-box;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     width: 100%;
</span><span class="cx">     height: 100%
</span><span class="cx"> }
</span><span class="lines">@@ -862,7 +848,6 @@
</span><span class="cx">     background-color: #000000;
</span><span class="cx">     border: 1px solid #777777;
</span><span class="cx">     -webkit-flex: 1;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if defined(ENABLE_DATALIST_ELEMENT) &amp;&amp; ENABLE_DATALIST_ELEMENT
</span><span class="lines">@@ -954,7 +939,6 @@
</span><span class="cx">     margin: 0;
</span><span class="cx">     -webkit-text-security: none;
</span><span class="cx">     -webkit-transition: opacity 05.5s ease;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> ::-webkit-validation-bubble-message {
</span><span class="lines">@@ -972,7 +956,6 @@
</span><span class="cx">     -webkit-box-shadow: 4px 4px 4px rgba(100,100,100,0.6),
</span><span class="cx">         inset -2px -2px 1px #d0c4c4,
</span><span class="cx">         inset 2px 2px 1px white;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     line-height: normal;
</span><span class="cx">     white-space: normal;
</span><span class="cx">     z-index: 2147483644;
</span><span class="lines">@@ -980,12 +963,10 @@
</span><span class="cx"> 
</span><span class="cx"> ::-webkit-validation-bubble-text-block {
</span><span class="cx">     -webkit-flex: 1;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> ::-webkit-validation-bubble-heading {
</span><span class="cx">     font-weight: bold;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> ::-webkit-validation-bubble-arrow {
</span><span class="lines">@@ -1001,7 +982,6 @@
</span><span class="cx">     box-shadow: inset 2px 2px 1px white;
</span><span class="cx">     -webkit-transform-origin: 0 0;
</span><span class="cx">     -webkit-transform: rotate(45deg);
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     z-index: 2147483645;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -1009,7 +989,6 @@
</span><span class="cx">     display: block;
</span><span class="cx">     overflow: hidden;
</span><span class="cx">     height: 16px;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if defined(ENABLE_METER_ELEMENT) &amp;&amp; ENABLE_METER_ELEMENT
</span><span class="lines">@@ -1027,7 +1006,6 @@
</span><span class="cx"> meter::-webkit-meter-inner-element {
</span><span class="cx">     -webkit-appearance: inherit;
</span><span class="cx">     box-sizing: inherit;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     height: 100%;
</span><span class="cx">     width: 100%;
</span><span class="cx"> }
</span><span class="lines">@@ -1036,28 +1014,24 @@
</span><span class="cx">     background: -webkit-gradient(linear, left top, left bottom, from(#ddd), to(#ddd), color-stop(0.20, #eee), color-stop(0.45, #ccc), color-stop(0.55, #ccc));
</span><span class="cx">     height: 100%;
</span><span class="cx">     width: 100%;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     box-sizing: border-box;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> meter::-webkit-meter-optimum-value {
</span><span class="cx">     background: -webkit-gradient(linear, left top, left bottom, from(#ad7), to(#ad7), color-stop(0.20, #cea), color-stop(0.45, #7a3), color-stop(0.55, #7a3));
</span><span class="cx">     height: 100%;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     box-sizing: border-box;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> meter::-webkit-meter-suboptimum-value {
</span><span class="cx">     background: -webkit-gradient(linear, left top, left bottom, from(#fe7), to(#fe7), color-stop(0.20, #ffc), color-stop(0.45, #db3), color-stop(0.55, #db3));
</span><span class="cx">     height: 100%;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     box-sizing: border-box;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> meter::-webkit-meter-even-less-good-value {
</span><span class="cx">     background: -webkit-gradient(linear, left top, left bottom, from(#f77), to(#f77), color-stop(0.20, #fcc), color-stop(0.45, #d44), color-stop(0.55, #d44));
</span><span class="cx">     height: 100%;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     box-sizing: border-box;
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="lines">@@ -1077,7 +1051,6 @@
</span><span class="cx"> progress::-webkit-progress-inner-element {
</span><span class="cx">     -webkit-appearance: inherit;
</span><span class="cx">     box-sizing: inherit;
</span><del>-    -webkit-user-modify: read-only;
</del><span class="cx">     height: 100%;
</span><span class="cx">     width: 100%;
</span><span class="cx"> }
</span><span class="lines">@@ -1086,7 +1059,6 @@
</span><span class="cx">     background-color: gray;
</span><span class="cx">     height: 100%;
</span><span class="cx">     width: 100%;
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     box-sizing: border-box;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -1094,7 +1066,6 @@
</span><span class="cx">     background-color: green;
</span><span class="cx">     height: 100%;
</span><span class="cx">     width: 50%; /* should be removed later */
</span><del>-    -webkit-user-modify: read-only !important;
</del><span class="cx">     box-sizing: border-box;
</span><span class="cx"> }
</span><span class="cx"> #endif
</span></span></pre>
</div>
</div>

</body>
</html>