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

Unified Diff: Source/core/editing/EditingStyle.cpp

Issue 1265853003: CSSValue Immediates: Immediates from all CSSPrimitiveValue constructors (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@tagged_ptrs_base
Patch Set: Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/css/parser/CSSPropertyParser.cpp ('k') | Source/core/editing/EditorCommand.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/editing/EditingStyle.cpp
diff --git a/Source/core/editing/EditingStyle.cpp b/Source/core/editing/EditingStyle.cpp
index a7e21ae31ed155aa76de83fa64d0fa492a693842..c9f8fcf63a7f89ec65f68c8631586d67495f0f3a 100644
--- a/Source/core/editing/EditingStyle.cpp
+++ b/Source/core/editing/EditingStyle.cpp
@@ -196,7 +196,7 @@ HTMLElementEquivalent::HTMLElementEquivalent(CSSPropertyID id, const HTMLQualifi
HTMLElementEquivalent::HTMLElementEquivalent(CSSPropertyID id, CSSValueID primitiveValue, const HTMLQualifiedName& tagName)
: m_propertyID(id)
- , m_primitiveValue(CSSPrimitiveValue::createIdentifier(primitiveValue))
+ , m_primitiveValue(CSSPrimitiveValue::create(primitiveValue))
, m_tagName(&tagName)
{
ASSERT(primitiveValue != CSSValueInvalid);
@@ -341,7 +341,7 @@ PassRefPtrWillBeRawPtr<CSSValue> HTMLFontSizeEquivalent::attributeValueAsCSSValu
CSSValueID size;
if (!HTMLFontElement::cssValueFromFontSizeNumber(value, size))
return nullptr;
- return CSSPrimitiveValue::createIdentifier(size);
+ return CSSPrimitiveValue::create(size);
}
float EditingStyle::NoFontDelta = 0.0f;
@@ -1124,8 +1124,8 @@ PassRefPtrWillBeRawPtr<EditingStyle> EditingStyle::wrappingStyleForSerialization
static void mergeTextDecorationValues(CSSValueList* mergedValue, const CSSValueList* valueToMerge)
{
- DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, underline, (CSSPrimitiveValue::createIdentifier(CSSValueUnderline)));
- DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, lineThrough, (CSSPrimitiveValue::createIdentifier(CSSValueLineThrough)));
+ DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, underline, (CSSPrimitiveValue::create(CSSValueUnderline)));
+ DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, lineThrough, (CSSPrimitiveValue::create(CSSValueLineThrough)));
if (valueToMerge->hasValue(underline) && !mergedValue->hasValue(underline))
mergedValue->append(underline);
@@ -1510,8 +1510,8 @@ void StyleChange::extractTextStyles(Document* document, MutableStylePropertySet*
// Furthermore, text-decoration: none has been trimmed so that text-decoration property is always a CSSValueList.
RefPtrWillBeRawPtr<CSSValue> textDecoration = style->getPropertyCSSValue(textDecorationPropertyForEditing());
if (textDecoration && textDecoration->isValueList()) {
- DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, underline, (CSSPrimitiveValue::createIdentifier(CSSValueUnderline)));
- DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, lineThrough, (CSSPrimitiveValue::createIdentifier(CSSValueLineThrough)));
+ DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, underline, (CSSPrimitiveValue::create(CSSValueUnderline)));
+ DEFINE_STATIC_REF_WILL_BE_PERSISTENT(CSSPrimitiveValue, lineThrough, (CSSPrimitiveValue::create(CSSValueLineThrough)));
RefPtrWillBeRawPtr<CSSValueList> newTextDecoration = toCSSValueList(textDecoration.get())->copy();
if (newTextDecoration->removeAll(underline))
m_applyUnderline = true;
« no previous file with comments | « Source/core/css/parser/CSSPropertyParser.cpp ('k') | Source/core/editing/EditorCommand.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698