Index: third_party/WebKit/Source/core/layout/LayoutListItem.cpp |
diff --git a/third_party/WebKit/Source/core/layout/LayoutListItem.cpp b/third_party/WebKit/Source/core/layout/LayoutListItem.cpp |
index 27cf22d899c4d652d62b3bf66d2dbb22e4dc9075..a0f1437b4c5a976bc5817b543f289d4ad2661ed0 100644 |
--- a/third_party/WebKit/Source/core/layout/LayoutListItem.cpp |
+++ b/third_party/WebKit/Source/core/layout/LayoutListItem.cpp |
@@ -63,6 +63,14 @@ void LayoutListItem::styleDidChange(StyleDifference diff, const ComputedStyle* o |
m_marker->destroy(); |
m_marker = nullptr; |
} |
+ |
+ StyleImage* oldImage = oldStyle ? oldStyle->listStyleImage() : nullptr; |
+ if (oldImage != style()->listStyleImage()) { |
+ if (oldImage) |
+ oldImage->removeClient(this); |
+ if (style()->listStyleImage()) |
+ style()->listStyleImage()->addClient(this); |
+ } |
} |
void LayoutListItem::willBeDestroyed() |
@@ -71,7 +79,11 @@ void LayoutListItem::willBeDestroyed() |
m_marker->destroy(); |
m_marker = nullptr; |
} |
+ |
LayoutBlockFlow::willBeDestroyed(); |
+ |
+ if (style() && style()->listStyleImage()) |
+ style()->listStyleImage()->removeClient(this); |
} |
void LayoutListItem::insertedIntoTree() |