Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(336)

Side by Side Diff: third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp

Issue 2597083002: Moved list-style-type to be generated in ComputedStyleBase (Closed)
Patch Set: Created 3 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
4 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) 5 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
7 * All rights reserved. 7 * All rights reserved.
8 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> 8 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org>
9 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> 9 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org>
10 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 10 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
(...skipping 740 matching lines...) Expand 10 before | Expand all | Expand 10 after
751 ContentData* firstContent = nullptr; 751 ContentData* firstContent = nullptr;
752 ContentData* prevContent = nullptr; 752 ContentData* prevContent = nullptr;
753 for (auto& item : toCSSValueList(value)) { 753 for (auto& item : toCSSValueList(value)) {
754 ContentData* nextContent = nullptr; 754 ContentData* nextContent = nullptr;
755 if (item->isImageGeneratorValue() || item->isImageSetValue() || 755 if (item->isImageGeneratorValue() || item->isImageSetValue() ||
756 item->isImageValue()) { 756 item->isImageValue()) {
757 nextContent = 757 nextContent =
758 ContentData::create(state.styleImage(CSSPropertyContent, *item)); 758 ContentData::create(state.styleImage(CSSPropertyContent, *item));
759 } else if (item->isCounterValue()) { 759 } else if (item->isCounterValue()) {
760 const CSSCounterValue* counterValue = toCSSCounterValue(item.get()); 760 const CSSCounterValue* counterValue = toCSSCounterValue(item.get());
761 EListStyleType listStyleType = EListStyleType::NoneListStyle; 761 EListStyleType listStyleType = EListStyleType::None;
762 CSSValueID listStyleIdent = counterValue->listStyle(); 762 CSSValueID listStyleIdent = counterValue->listStyle();
763 if (listStyleIdent != CSSValueNone) 763 if (listStyleIdent != CSSValueNone)
764 listStyleType = 764 listStyleType =
765 static_cast<EListStyleType>(listStyleIdent - CSSValueDisc); 765 static_cast<EListStyleType>(listStyleIdent - CSSValueDisc);
766 std::unique_ptr<CounterContent> counter = 766 std::unique_ptr<CounterContent> counter =
767 WTF::wrapUnique(new CounterContent( 767 WTF::wrapUnique(new CounterContent(
768 AtomicString(counterValue->identifier()), listStyleType, 768 AtomicString(counterValue->identifier()), listStyleType,
769 AtomicString(counterValue->separator()))); 769 AtomicString(counterValue->separator())));
770 nextContent = ContentData::create(std::move(counter)); 770 nextContent = ContentData::create(std::move(counter));
771 } else if (item->isIdentifierValue()) { 771 } else if (item->isIdentifierValue()) {
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after
1033 state.style()->setCaretColor( 1033 state.style()->setCaretColor(
1034 StyleBuilderConverter::convertStyleAutoColor(state, value)); 1034 StyleBuilderConverter::convertStyleAutoColor(state, value));
1035 } 1035 }
1036 if (state.applyPropertyToVisitedLinkStyle()) { 1036 if (state.applyPropertyToVisitedLinkStyle()) {
1037 state.style()->setVisitedLinkCaretColor( 1037 state.style()->setVisitedLinkCaretColor(
1038 StyleBuilderConverter::convertStyleAutoColor(state, value, true)); 1038 StyleBuilderConverter::convertStyleAutoColor(state, value, true));
1039 } 1039 }
1040 } 1040 }
1041 1041
1042 } // namespace blink 1042 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698