| Index: Source/core/css/StylePropertySet.cpp
|
| diff --git a/Source/core/css/StylePropertySet.cpp b/Source/core/css/StylePropertySet.cpp
|
| index 78d600fa42a745186c47def4ecc99be6b5d77c6e..6e432336a38860c0e1bcd89016a365c1c13c0437 100644
|
| --- a/Source/core/css/StylePropertySet.cpp
|
| +++ b/Source/core/css/StylePropertySet.cpp
|
| @@ -137,19 +137,19 @@ MutableStylePropertySet::MutableStylePropertySet(const StylePropertySet& other)
|
|
|
| String StylePropertySet::getPropertyValue(CSSPropertyID propertyID) const
|
| {
|
| - NullableCSSValue value = getPropertyCSSValue(propertyID);
|
| + const NullableCSSValue& value = getPropertyCSSValue(propertyID);
|
| if (value)
|
| return value->cssText();
|
|
|
| return StylePropertySerializer(*this).getPropertyValue(propertyID);
|
| }
|
|
|
| -NullableCSSValue StylePropertySet::getPropertyCSSValue(CSSPropertyID propertyID) const
|
| +const NullableCSSValue StylePropertySet::getPropertyCSSValue(CSSPropertyID propertyID) const
|
| {
|
| int foundPropertyIndex = findPropertyIndex(propertyID);
|
| if (foundPropertyIndex == -1)
|
| return nullptr;
|
| - return propertyAt(foundPropertyIndex).value();
|
| + return *reinterpret_cast<const NullableCSSValue*>(&propertyAt(foundPropertyIndex).value());
|
| }
|
|
|
| DEFINE_TRACE(StylePropertySet)
|
| @@ -439,7 +439,7 @@ PassRefPtrWillBeRawPtr<MutableStylePropertySet> StylePropertySet::copyProperties
|
| WillBeHeapVector<CSSProperty, 256> list;
|
| list.reserveInitialCapacity(properties.size());
|
| for (unsigned i = 0; i < properties.size(); ++i) {
|
| - NullableCSSValue value = getPropertyCSSValue(properties[i]);
|
| + const NullableCSSValue& value = getPropertyCSSValue(properties[i]);
|
| if (value)
|
| list.append(CSSProperty(properties[i], *value, false));
|
| }
|
|
|