| Index: third_party/WebKit/Source/platform/fonts/FontDescription.cpp
|
| diff --git a/third_party/WebKit/Source/platform/fonts/FontDescription.cpp b/third_party/WebKit/Source/platform/fonts/FontDescription.cpp
|
| index f661da242b643e087e39c8feb80c9782b4cc8d86..b7e838ca9c28ce90b70ee07a3c2312f150f9c396 100644
|
| --- a/third_party/WebKit/Source/platform/fonts/FontDescription.cpp
|
| +++ b/third_party/WebKit/Source/platform/fonts/FontDescription.cpp
|
| @@ -42,7 +42,7 @@ struct SameSizeAsFontDescription {
|
| RefPtr<FontFeatureSettings> m_featureSettings;
|
| AtomicString locale;
|
| float sizes[6];
|
| - uint32_t bitfields[2];
|
| + FieldsAsUnsignedType bitfields;
|
| };
|
|
|
| static_assert(sizeof(FontDescription) == sizeof(SameSizeAsFontDescription), "FontDescription should stay small");
|
| @@ -161,6 +161,13 @@ void FontDescription::setVariantLigatures(const VariantLigatures& ligatures)
|
| updateTypesettingFeatures();
|
| }
|
|
|
| +void FontDescription::setVariantNumeric(const FontVariantNumeric& variantNumeric)
|
| +{
|
| + m_fields.m_variantNumeric = variantNumeric.m_fieldsAsUnsigned;
|
| +
|
| + updateTypesettingFeatures();
|
| +}
|
| +
|
| float FontDescription::effectiveFontSize() const
|
| {
|
| // Ensure that the effective precision matches the font-cache precision.
|
| @@ -281,8 +288,8 @@ unsigned FontDescription::styleHashWithoutFamilyList() const
|
| addFloatToHash(hash, m_sizeAdjust);
|
| addFloatToHash(hash, m_letterSpacing);
|
| addFloatToHash(hash, m_wordSpacing);
|
| - addToHash(hash, m_fieldsAsUnsigned[0]);
|
| - addToHash(hash, m_fieldsAsUnsigned[1]);
|
| + addToHash(hash, m_fieldsAsUnsigned.parts[0]);
|
| + addToHash(hash, m_fieldsAsUnsigned.parts[1]);
|
|
|
| return hash;
|
| }
|
|
|