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

Unified Diff: Source/core/css/FontFace.cpp

Issue 1249553002: CSSValue Immediates: Add move operators to CSSPrimitiveValue (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@cssvalue_patch_3_tagged_ptrs_with_copy_ops_mv_operators_ref_primvalue
Patch Set: Rebase 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/Counter.h ('k') | Source/core/css/Pair.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/FontFace.cpp
diff --git a/Source/core/css/FontFace.cpp b/Source/core/css/FontFace.cpp
index c7e204e691b35edd2b93e51fa7960f141ece4737..ad9e453bad85b2f20bac7ab6a69c783bef9902cc 100644
--- a/Source/core/css/FontFace.cpp
+++ b/Source/core/css/FontFace.cpp
@@ -113,10 +113,10 @@ PassRefPtrWillBeRawPtr<FontFace> FontFace::create(Document* document, const Styl
const StylePropertySet& properties = fontFaceRule->properties();
// Obtain the font-family property and the src property. Both must be defined.
- NullableCSSValue family = properties.getPropertyCSSValue(CSSPropertyFontFamily);
+ const NullableCSSValue& family = properties.getPropertyCSSValue(CSSPropertyFontFamily);
if (!family || !family->isValueList())
return nullptr;
- NullableCSSValue src = properties.getPropertyCSSValue(CSSPropertySrc);
+ const NullableCSSValue& src = properties.getPropertyCSSValue(CSSPropertySrc);
if (!src || !src->isValueList())
return nullptr;
@@ -278,7 +278,7 @@ bool FontFace::setFamilyValue(CSSValueList* familyList)
if (familyList->length() != 1)
return false;
- CSSPrimitiveValue& familyValue = toCSSPrimitiveValue(familyList->item(0));
+ const CSSPrimitiveValue& familyValue = toCSSPrimitiveValue(familyList->item(0));
AtomicString family;
if (familyValue.isCustomIdent()) {
family = AtomicString(familyValue.getStringValue());
@@ -405,7 +405,7 @@ FontTraits FontFace::traits() const
if (!m_style->isPrimitiveValue())
return 0;
- switch (toCSSPrimitiveValue(m_style)->getValueID()) {
+ switch (toCSSPrimitiveValue(m_style).getValueID()) {
case CSSValueNormal:
style = FontStyleNormal;
break;
@@ -423,7 +423,7 @@ FontTraits FontFace::traits() const
if (!m_weight->isPrimitiveValue())
return 0;
- switch (toCSSPrimitiveValue(m_weight)->getValueID()) {
+ switch (toCSSPrimitiveValue(m_weight).getValueID()) {
case CSSValueBold:
case CSSValue700:
weight = FontWeight700;
« no previous file with comments | « Source/core/css/Counter.h ('k') | Source/core/css/Pair.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698