Fix for 3716082, assert when you dynamically remove float or position styles.
authorhyatt <hyatt@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 14 Jul 2004 20:13:54 +0000 (20:13 +0000)
committerhyatt <hyatt@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 14 Jul 2004 20:13:54 +0000 (20:13 +0000)
        Reviewed by kevin

        * khtml/rendering/render_object.cpp:
        (RenderObject::setStyle):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@7026 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebCore/ChangeLog-2005-08-23
WebCore/khtml/rendering/render_object.cpp

index ebc9101..8c0d281 100644 (file)
@@ -1,5 +1,14 @@
 2004-07-14  David Hyatt  <hyatt@apple.com>
 
+       Fix for 3716082, assert when you dynamically remove float or position styles.
+       
+        Reviewed by kevin
+
+        * khtml/rendering/render_object.cpp:
+        (RenderObject::setStyle):
+
+2004-07-14  David Hyatt  <hyatt@apple.com>
+
        Fix for various table regressions (malumovies.com and cityofheroes.gameamp.com) involving bungling of
        percentage heights.
        
index 1b99f92..66397f4 100644 (file)
@@ -1522,16 +1522,16 @@ void RenderObject::setStyle(RenderStyle *style)
             // from the positioned objects list.
             removeFromObjectLists();
         
+        affectsParentBlock = m_style && isFloatingOrPositioned() &&
+            (!style->isFloating() && style->position() != ABSOLUTE && style->position() != FIXED)
+            && parent() && (parent()->isBlockFlow() || parent()->isInlineFlow());
+        
         // reset style flags
         m_floating = false;
         m_positioned = false;
         m_relPositioned = false;
         m_paintBackground = false;
         m_hasOverflowClip = false;
-        
-        affectsParentBlock = m_style && isFloatingOrPositioned() &&
-            (!style->isFloating() && style->position() != ABSOLUTE && style->position() != FIXED)
-            && parent() && (parent()->isBlockFlow() || parent()->isInlineFlow());
     }
 
     RenderStyle *oldStyle = m_style;