Title: [158099] trunk/Source/WebCore
Revision
158099
Author
[email protected]
Date
2013-10-27 17:17:44 -0700 (Sun, 27 Oct 2013)

Log Message

Tone down overzealous assertion from r158097.

RenderElement::initializeStyle() really only cares that there are no
text renderers that we should be calling styleDidChange() on.

Tweak the code to only check that there are no text children.

* rendering/RenderElement.cpp:
(WebCore::RenderElement::initializeStyle):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (158098 => 158099)


--- trunk/Source/WebCore/ChangeLog	2013-10-27 23:06:41 UTC (rev 158098)
+++ trunk/Source/WebCore/ChangeLog	2013-10-28 00:17:44 UTC (rev 158099)
@@ -1,3 +1,15 @@
+2013-10-27  Andreas Kling  <[email protected]>
+
+        Tone down overzealous assertion from r158097.
+
+        RenderElement::initializeStyle() really only cares that there are no
+        text renderers that we should be calling styleDidChange() on.
+
+        Tweak the code to only check that there are no text children.
+
+        * rendering/RenderElement.cpp:
+        (WebCore::RenderElement::initializeStyle):
+
 2013-10-27  Antti Koivisto  <[email protected]>
 
         Enable center and right text alignment for simple lines

Modified: trunk/Source/WebCore/rendering/RenderElement.cpp (158098 => 158099)


--- trunk/Source/WebCore/rendering/RenderElement.cpp	2013-10-27 23:06:41 UTC (rev 158098)
+++ trunk/Source/WebCore/rendering/RenderElement.cpp	2013-10-28 00:17:44 UTC (rev 158099)
@@ -372,8 +372,11 @@
 
     styleDidChange(StyleDifferenceEqual, nullptr);
 
-    // We shouldn't have any text (or other) children that need styleDidChange at this point.
-    ASSERT(!firstChild());
+#if !ASSERT_DISABLED
+    // We shouldn't have any text children that would need styleDidChange at this point.
+    for (RenderObject* child = firstChild(); child; child = child->nextSibling())
+        ASSERT(!child->isText());
+#endif
 
     // It would be nice to assert that !parent() here, but some RenderLayer subrenderers
     // have their parent set before getting a call to initializeStyle() :|
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to