Index: Source/core/css/Pair.h |
diff --git a/Source/core/css/Pair.h b/Source/core/css/Pair.h |
index 4df5efec58f714f5d1a0436552a52558d82b5d55..f9f20c2d757418469c2fa8fd117b6ca9ba7b0f09 100644 |
--- a/Source/core/css/Pair.h |
+++ b/Source/core/css/Pair.h |
@@ -22,7 +22,7 @@ |
#define Pair_h |
#include "core/CoreExport.h" |
-#include "core/css/CSSPrimitiveValue.h" |
+#include "core/css/CSSValue.h" |
#include "wtf/PassRefPtr.h" |
#include "wtf/RefCounted.h" |
#include "wtf/text/StringBuilder.h" |
@@ -33,18 +33,18 @@ namespace blink { |
// and border-spacing (all of which are space-separated sets of two values). At the moment we are only using it for |
// border-radius and background-size, but (FIXME) border-spacing and background-position could be converted over to use |
// it (eliminating some extra -webkit- internal properties). |
-class CORE_EXPORT Pair final : public RefCountedWillBeGarbageCollected<Pair> { |
+class CORE_EXPORT Pair final : public RefCountedWillBeGarbageCollectedFinalized<Pair> { |
public: |
enum IdenticalValuesPolicy { DropIdenticalValues, KeepIdenticalValues }; |
- static PassRefPtrWillBeRawPtr<Pair> create(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> first, PassRefPtrWillBeRawPtr<CSSPrimitiveValue> second, |
+ static PassRefPtrWillBeRawPtr<Pair> create(CSSPrimitiveValue first, CSSPrimitiveValue second, |
IdenticalValuesPolicy identicalValuesPolicy) |
{ |
return adoptRefWillBeNoop(new Pair(first, second, identicalValuesPolicy)); |
} |
- CSSPrimitiveValue* first() const { return m_first.get(); } |
- CSSPrimitiveValue* second() const { return m_second.get(); } |
+ NullableCSSValue first() const { return m_first; } |
+ NullableCSSValue second() const { return m_second; } |
String cssText() const |
{ |
@@ -53,15 +53,15 @@ public: |
bool equals(const Pair& other) const |
{ |
- return compareCSSValuePtr(m_first, other.m_first) |
- && compareCSSValuePtr(m_second, other.m_second) |
+ return m_first == other.m_first |
+ && m_second == other.m_second |
&& m_identicalValuesPolicy == other.m_identicalValuesPolicy; |
} |
DECLARE_TRACE(); |
private: |
- Pair(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> first, PassRefPtrWillBeRawPtr<CSSPrimitiveValue> second, IdenticalValuesPolicy identicalValuesPolicy) |
+ Pair(CSSPrimitiveValue first, CSSPrimitiveValue second, IdenticalValuesPolicy identicalValuesPolicy) |
: m_first(first) |
, m_second(second) |
, m_identicalValuesPolicy(identicalValuesPolicy) { } |
@@ -73,8 +73,8 @@ private: |
return first + ' ' + second; |
} |
- RefPtrWillBeMember<CSSPrimitiveValue> m_first; |
- RefPtrWillBeMember<CSSPrimitiveValue> m_second; |
+ NullableCSSValue m_first; |
+ NullableCSSValue m_second; |
IdenticalValuesPolicy m_identicalValuesPolicy; |
}; |