Title: [153608] trunk
- Revision
- 153608
- Author
- [email protected]
- Date
- 2013-08-01 14:25:33 -0700 (Thu, 01 Aug 2013)
Log Message
REGRESSION (Safari 6 - ToT): Incorrectly assumes that RenderStyle data can be shared
https://bugs.webkit.org/show_bug.cgi?id=113058
Source/WebCore:
Before sharing CSS properties with an element in the cache, we need to
check that the new element is suitable for this, just like we check
elements before inserting them into the cache.
Patch by Morten Stenshorne <[email protected]> on 2013-08-01
Reviewed by Andreas Kling.
Test: fast/css/identical-logical-height-decl.html
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyMatchedProperties):
LayoutTests:
Patch by Morten Stenshorne <[email protected]> on 2013-08-01
Reviewed by Andreas Kling.
* fast/css/identical-logical-height-decl-expected.html: Added.
* fast/css/identical-logical-height-decl.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (153607 => 153608)
--- trunk/LayoutTests/ChangeLog 2013-08-01 21:13:11 UTC (rev 153607)
+++ trunk/LayoutTests/ChangeLog 2013-08-01 21:25:33 UTC (rev 153608)
@@ -1,3 +1,13 @@
+2013-08-01 Morten Stenshorne <[email protected]>
+
+ REGRESSION (Safari 6 - ToT): Incorrectly assumes that RenderStyle data can be shared
+ https://bugs.webkit.org/show_bug.cgi?id=113058
+
+ Reviewed by Andreas Kling.
+
+ * fast/css/identical-logical-height-decl-expected.html: Added.
+ * fast/css/identical-logical-height-decl.html: Added.
+
2013-08-01 Simon Fraser <[email protected]>
Mark some ref tests that sometimes file becaues of colorspace
Added: trunk/LayoutTests/fast/css/identical-logical-height-decl-expected.html (0 => 153608)
--- trunk/LayoutTests/fast/css/identical-logical-height-decl-expected.html (rev 0)
+++ trunk/LayoutTests/fast/css/identical-logical-height-decl-expected.html 2013-08-01 21:25:33 UTC (rev 153608)
@@ -0,0 +1,9 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>Identical style declaration on elements with different writing modes</title>
+ </head>
+ <body style="overflow:hidden;">
+ <p>There should be no red on this page.</p>
+ </body>
+</html>
Added: trunk/LayoutTests/fast/css/identical-logical-height-decl.html (0 => 153608)
--- trunk/LayoutTests/fast/css/identical-logical-height-decl.html (rev 0)
+++ trunk/LayoutTests/fast/css/identical-logical-height-decl.html 2013-08-01 21:25:33 UTC (rev 153608)
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>Identical style declaration on elements with different writing modes</title>
+ </head>
+ <body style="overflow:hidden;">
+ <p>There should be no red on this page.</p>
+ <div style="-webkit-logical-height:10px;"></div> <!-- set height -->
+ <div style="-webkit-writing-mode:vertical-lr; width:100px; height:100px; background:red;">
+ <div style="-webkit-logical-height:10px;"> <!-- set width! -->
+ <div style="width:100px; background:white;"></div>
+ </div>
+ </div>
+ </body>
+</html>
Modified: trunk/Source/WebCore/ChangeLog (153607 => 153608)
--- trunk/Source/WebCore/ChangeLog 2013-08-01 21:13:11 UTC (rev 153607)
+++ trunk/Source/WebCore/ChangeLog 2013-08-01 21:25:33 UTC (rev 153608)
@@ -1,3 +1,19 @@
+2013-08-01 Morten Stenshorne <[email protected]>
+
+ REGRESSION (Safari 6 - ToT): Incorrectly assumes that RenderStyle data can be shared
+ https://bugs.webkit.org/show_bug.cgi?id=113058
+
+ Before sharing CSS properties with an element in the cache, we need to
+ check that the new element is suitable for this, just like we check
+ elements before inserting them into the cache.
+
+ Reviewed by Andreas Kling.
+
+ Test: fast/css/identical-logical-height-decl.html
+
+ * css/StyleResolver.cpp:
+ (WebCore::StyleResolver::applyMatchedProperties):
+
2013-08-01 Mark Lam <[email protected]>
Fixed expected test results for run-bindings-tests after r153532, r153537.
Modified: trunk/Source/WebCore/css/StyleResolver.cpp (153607 => 153608)
--- trunk/Source/WebCore/css/StyleResolver.cpp 2013-08-01 21:13:11 UTC (rev 153607)
+++ trunk/Source/WebCore/css/StyleResolver.cpp 2013-08-01 21:25:33 UTC (rev 153608)
@@ -1846,7 +1846,8 @@
unsigned cacheHash = matchResult.isCacheable ? computeMatchedPropertiesHash(matchResult.matchedProperties.data(), matchResult.matchedProperties.size()) : 0;
bool applyInheritedOnly = false;
const MatchedPropertiesCacheItem* cacheItem = 0;
- if (cacheHash && (cacheItem = findFromMatchedPropertiesCache(cacheHash, matchResult))) {
+ if (cacheHash && (cacheItem = findFromMatchedPropertiesCache(cacheHash, matchResult))
+ && isCacheableInMatchedPropertiesCache(element, state.style(), state.parentStyle())) {
// We can build up the style by copying non-inherited properties from an earlier style object built using the same exact
// style declarations. We then only need to apply the inherited properties, if any, as their values can depend on the
// element context. This is fast and saves memory by reusing the style data structures.
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes