 Chromium Code Reviews
 Chromium Code Reviews Issue 1403643002:
  Rework list marker spacing for better web compatibility.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@472084_use_list_item_painter
    
  
    Issue 1403643002:
  Rework list marker spacing for better web compatibility.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@472084_use_list_item_painter| 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 bcf21d089a3ceef02eafba879f55619e5675c56e..fc73d5a54cd898bcc8eb27d31b33ca5800f9e5fa 100644 | 
| --- a/third_party/WebKit/Source/core/layout/LayoutListItem.cpp | 
| +++ b/third_party/WebKit/Source/core/layout/LayoutListItem.cpp | 
| @@ -54,8 +54,9 @@ void LayoutListItem::styleDidChange(StyleDifference diff, const ComputedStyle* o | 
| { | 
| LayoutBlockFlow::styleDidChange(diff, oldStyle); | 
| + StyleImage* currentImage = style()->listStyleImage(); | 
| if (style()->listStyleType() != NoneListStyle | 
| - || (style()->listStyleImage() && !style()->listStyleImage()->errorOccurred())) { | 
| + || (currentImage && !currentImage->errorOccurred())) { | 
| 
wkorman
2015/10/14 01:55:30
codereview UI isn't showing your comment in-line h
 | 
| if (!m_marker) | 
| m_marker = LayoutListMarker::createAnonymous(this); | 
| m_marker->listItemStyleDidChange(); | 
| @@ -66,11 +67,11 @@ void LayoutListItem::styleDidChange(StyleDifference diff, const ComputedStyle* o | 
| } | 
| StyleImage* oldImage = oldStyle ? oldStyle->listStyleImage() : nullptr; | 
| - if (oldImage != style()->listStyleImage()) { | 
| + if (oldImage != currentImage) { | 
| if (oldImage) | 
| oldImage->removeClient(this); | 
| - if (style()->listStyleImage()) | 
| - style()->listStyleImage()->addClient(this); | 
| + if (currentImage) | 
| + currentImage->addClient(this); | 
| } | 
| } | 
| @@ -219,7 +220,7 @@ inline int LayoutListItem::calcValue() const | 
| return m_explicitValue; | 
| Node* list = enclosingList(this); | 
| - HTMLOListElement* oListElement = isHTMLOListElement(list) ? toHTMLOListElement(list) : 0; | 
| + HTMLOListElement* oListElement = isHTMLOListElement(list) ? toHTMLOListElement(list) : nullptr; | 
| int valueStep = 1; | 
| if (oListElement && oListElement->isReversed()) | 
| valueStep = -1; |