| Index: Source/core/editing/StyledMarkupAccumulator.cpp
|
| diff --git a/Source/core/editing/StyledMarkupAccumulator.cpp b/Source/core/editing/StyledMarkupAccumulator.cpp
|
| index a4496f6efe65f489376710645441bc4c0fea2117..e0d76a74aff50c15136289a1df774818b0790541 100644
|
| --- a/Source/core/editing/StyledMarkupAccumulator.cpp
|
| +++ b/Source/core/editing/StyledMarkupAccumulator.cpp
|
| @@ -143,15 +143,15 @@ void StyledMarkupAccumulator::appendText(StringBuilder& out, Text& text)
|
|
|
| void StyledMarkupAccumulator::appendElement(StringBuilder& out, Element& element, Namespaces*)
|
| {
|
| - appendElement(out, element, false, DoesFullySelectNode);
|
| + appendElement(out, element, AddDisplayInline::DoesNotAdd, RangeFullySelectsNode::DoesSelect);
|
| }
|
|
|
| -void StyledMarkupAccumulator::appendElement(StringBuilder& out, Element& element, bool addDisplayInline, StyledMarkupAccumulator::RangeFullySelectsNode rangeFullySelectsNode)
|
| +void StyledMarkupAccumulator::appendElement(StringBuilder& out, Element& element, AddDisplayInline addDisplayInline, RangeFullySelectsNode rangeFullySelectsNode)
|
| {
|
| const bool documentIsHTML = element.document().isHTMLDocument();
|
| m_accumulator.appendOpenTag(out, element, 0);
|
|
|
| - const bool shouldAnnotateOrForceInline = element.isHTMLElement() && (shouldAnnotate() || addDisplayInline);
|
| + const bool shouldAnnotateOrForceInline = element.isHTMLElement() && (shouldAnnotate() || addDisplayInline == AddDisplayInline::DoesAdd);
|
| const bool shouldOverrideStyleAttr = shouldAnnotateOrForceInline || shouldApplyWrappingStyle(element);
|
|
|
| AttributeCollection attributes = element.attributes();
|
| @@ -180,12 +180,12 @@ void StyledMarkupAccumulator::appendElement(StringBuilder& out, Element& element
|
| if (shouldAnnotate())
|
| newInlineStyle->mergeStyleFromRulesForSerialization(&toHTMLElement(element));
|
|
|
| - if (addDisplayInline)
|
| + if (addDisplayInline == AddDisplayInline::DoesAdd)
|
| newInlineStyle->forceInline();
|
|
|
| // If the node is not fully selected by the range, then we don't want to keep styles that affect its relationship to the nodes around it
|
| // only the ones that affect it and the nodes within it.
|
| - if (rangeFullySelectsNode == DoesNotFullySelectNode && newInlineStyle->style())
|
| + if (rangeFullySelectsNode == RangeFullySelectsNode::DoesNotSelect && newInlineStyle->style())
|
| newInlineStyle->style()->removeProperty(CSSPropertyFloat);
|
| }
|
|
|
| @@ -199,11 +199,11 @@ void StyledMarkupAccumulator::appendElement(StringBuilder& out, Element& element
|
| m_accumulator.appendCloseTag(out, element);
|
| }
|
|
|
| -void StyledMarkupAccumulator::appendStyleNodeOpenTag(StringBuilder& out, StylePropertySet* style, bool isBlock)
|
| +void StyledMarkupAccumulator::appendStyleNodeOpenTag(StringBuilder& out, StylePropertySet* style, StyleTagType isBlock)
|
| {
|
| // wrappingStyleForSerialization should have removed -webkit-text-decorations-in-effect
|
| ASSERT(propertyMissingOrEqualToNone(style, CSSPropertyWebkitTextDecorationsInEffect));
|
| - if (isBlock)
|
| + if (isBlock == StyleTagType::Block)
|
| out.appendLiteral("<div style=\"");
|
| else
|
| out.appendLiteral("<span style=\"");
|
|
|