Index: Source/core/rendering/RenderBox.cpp |
diff --git a/Source/core/rendering/RenderBox.cpp b/Source/core/rendering/RenderBox.cpp |
index 849f7def1309120b39c6b6eda32c4e9960a043c3..335e5e5333569d568b8b68c4b5818ef8843fc3d5 100644 |
--- a/Source/core/rendering/RenderBox.cpp |
+++ b/Source/core/rendering/RenderBox.cpp |
@@ -164,8 +164,17 @@ void RenderBox::removeFloatingOrPositionedChildFromBlockLists() |
} |
} |
- if (isOutOfFlowPositioned()) |
- RenderBlock::removePositionedObject(this); |
+ if (isOutOfFlowPositioned()) { |
+ RenderBlock* block = const_cast<RenderBlock*>(toRenderBlock(this)); |
+ ASSERT(block); |
+ for (RenderObject* curr = parent(); curr; curr = curr->parent()) { |
+ ASSERT(curr); |
+ if (curr->isRenderBlock()) { |
+ // toRenderBlock(curr)->removePositionedObject(this); |
+ toRenderBlock(curr)->removePositionedObjects(block, NewContainingBlock); |
+ } |
+ } |
+ } |
} |
void RenderBox::styleWillChange(StyleDifference diff, const RenderStyle& newStyle) |