| Index: third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| diff --git a/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp b/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| index a32acd73177428e1ecc8af92d6a37da71502e5db..c9739d5e7db4b6437c277482fed2e340bbc52b6e 100644
|
| --- a/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| +++ b/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| @@ -92,6 +92,7 @@ static inline bool isValidVisitedLinkProperty(CSSPropertyID id) {
|
| case CSSPropertyBorderRightColor:
|
| case CSSPropertyBorderTopColor:
|
| case CSSPropertyBorderBottomColor:
|
| + case CSSPropertyCaretColor:
|
| case CSSPropertyColor:
|
| case CSSPropertyFill:
|
| case CSSPropertyOutlineColor:
|
| @@ -1041,4 +1042,35 @@ void StyleBuilderFunctions::applyInheritCSSPropertyPosition(
|
| state.style()->setPosition(state.parentStyle()->position());
|
| }
|
|
|
| +void StyleBuilderFunctions::applyInitialCSSPropertyCaretColor(
|
| + StyleResolverState& state) {
|
| + StyleAutoColor color = StyleAutoColor::autoColor();
|
| + if (state.applyPropertyToRegularStyle())
|
| + state.style()->setCaretColor(color);
|
| + if (state.applyPropertyToVisitedLinkStyle())
|
| + state.style()->setVisitedLinkCaretColor(color);
|
| +}
|
| +
|
| +void StyleBuilderFunctions::applyInheritCSSPropertyCaretColor(
|
| + StyleResolverState& state) {
|
| + StyleAutoColor color = state.parentStyle()->caretColor();
|
| + if (state.applyPropertyToRegularStyle())
|
| + state.style()->setCaretColor(color);
|
| + if (state.applyPropertyToVisitedLinkStyle())
|
| + state.style()->setVisitedLinkCaretColor(color);
|
| +}
|
| +
|
| +void StyleBuilderFunctions::applyValueCSSPropertyCaretColor(
|
| + StyleResolverState& state,
|
| + const CSSValue& value) {
|
| + if (state.applyPropertyToRegularStyle()) {
|
| + state.style()->setCaretColor(
|
| + StyleBuilderConverter::convertStyleAutoColor(state, value));
|
| + }
|
| + if (state.applyPropertyToVisitedLinkStyle()) {
|
| + state.style()->setVisitedLinkCaretColor(
|
| + StyleBuilderConverter::convertStyleAutoColor(state, value, true));
|
| + }
|
| +}
|
| +
|
| } // namespace blink
|
|
|