| OLD | NEW |
| 1 /* | 1 /* |
| 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) | 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 bool isBaseValueList() const { return m_classType == ValueListClass; } | 65 bool isBaseValueList() const { return m_classType == ValueListClass; } |
| 66 | 66 |
| 67 bool isBasicShapeValue() const { return m_classType >= BasicShapeCircleClass
&& m_classType <= BasicShapeInsetClass; } | 67 bool isBasicShapeValue() const { return m_classType >= BasicShapeCircleClass
&& m_classType <= BasicShapeInsetClass; } |
| 68 bool isBasicShapeCircleValue() const { return m_classType == BasicShapeCircl
eClass; } | 68 bool isBasicShapeCircleValue() const { return m_classType == BasicShapeCircl
eClass; } |
| 69 bool isBasicShapeEllipseValue() const { return m_classType == BasicShapeElli
pseClass; } | 69 bool isBasicShapeEllipseValue() const { return m_classType == BasicShapeElli
pseClass; } |
| 70 bool isBasicShapePolygonValue() const { return m_classType == BasicShapePoly
gonClass; } | 70 bool isBasicShapePolygonValue() const { return m_classType == BasicShapePoly
gonClass; } |
| 71 bool isBasicShapeInsetValue() const { return m_classType == BasicShapeInsetC
lass; } | 71 bool isBasicShapeInsetValue() const { return m_classType == BasicShapeInsetC
lass; } |
| 72 | 72 |
| 73 bool isBorderImageSliceValue() const { return m_classType == BorderImageSlic
eClass; } | 73 bool isBorderImageSliceValue() const { return m_classType == BorderImageSlic
eClass; } |
| 74 bool isCanvasValue() const { return m_classType == CanvasClass; } | 74 bool isCanvasValue() const { return m_classType == CanvasClass; } |
| 75 bool isColorValue() const { return m_classType == ColorClass; } |
| 75 bool isCounterValue() const { return m_classType == CounterClass; } | 76 bool isCounterValue() const { return m_classType == CounterClass; } |
| 76 bool isCursorImageValue() const { return m_classType == CursorImageClass; } | 77 bool isCursorImageValue() const { return m_classType == CursorImageClass; } |
| 77 bool isCrossfadeValue() const { return m_classType == CrossfadeClass; } | 78 bool isCrossfadeValue() const { return m_classType == CrossfadeClass; } |
| 78 bool isFontFeatureValue() const { return m_classType == FontFeatureClass; } | 79 bool isFontFeatureValue() const { return m_classType == FontFeatureClass; } |
| 79 bool isFontFaceSrcValue() const { return m_classType == FontFaceSrcClass; } | 80 bool isFontFaceSrcValue() const { return m_classType == FontFaceSrcClass; } |
| 80 bool isFunctionValue() const { return m_classType == FunctionClass; } | 81 bool isFunctionValue() const { return m_classType == FunctionClass; } |
| 81 bool isCustomIdentValue() const { return m_classType == CustomIdentClass; } | 82 bool isCustomIdentValue() const { return m_classType == CustomIdentClass; } |
| 82 bool isImageGeneratorValue() const { return m_classType >= CanvasClass && m_
classType <= RadialGradientClass; } | 83 bool isImageGeneratorValue() const { return m_classType >= CanvasClass && m_
classType <= RadialGradientClass; } |
| 83 bool isGradientValue() const { return m_classType >= LinearGradientClass &&
m_classType <= RadialGradientClass; } | 84 bool isGradientValue() const { return m_classType >= LinearGradientClass &&
m_classType <= RadialGradientClass; } |
| 84 bool isImageSetValue() const { return m_classType == ImageSetClass; } | 85 bool isImageSetValue() const { return m_classType == ImageSetClass; } |
| (...skipping 30 matching lines...) Expand all Loading... |
| 115 // ~CSSValue should be public, because non-public ~CSSValue causes C2248 | 116 // ~CSSValue should be public, because non-public ~CSSValue causes C2248 |
| 116 // error: 'blink::CSSValue::~CSSValue' : cannot access protected member | 117 // error: 'blink::CSSValue::~CSSValue' : cannot access protected member |
| 117 // declared in class 'blink::CSSValue' when compiling | 118 // declared in class 'blink::CSSValue' when compiling |
| 118 // 'source\wtf\refcounted.h' by using msvc. | 119 // 'source\wtf\refcounted.h' by using msvc. |
| 119 ~CSSValue() { } | 120 ~CSSValue() { } |
| 120 | 121 |
| 121 protected: | 122 protected: |
| 122 static const size_t ClassTypeBits = 6; | 123 static const size_t ClassTypeBits = 6; |
| 123 enum ClassType { | 124 enum ClassType { |
| 124 PrimitiveClass, | 125 PrimitiveClass, |
| 126 ColorClass, |
| 125 CounterClass, | 127 CounterClass, |
| 126 QuadClass, | 128 QuadClass, |
| 127 CustomIdentClass, | 129 CustomIdentClass, |
| 128 StringClass, | 130 StringClass, |
| 129 URIClass, | 131 URIClass, |
| 130 ValuePairClass, | 132 ValuePairClass, |
| 131 | 133 |
| 132 // Basic shape classes. | 134 // Basic shape classes. |
| 133 // TODO(sashab): Represent these as a single subclass, BasicShapeClass. | 135 // TODO(sashab): Represent these as a single subclass, BasicShapeClass. |
| 134 BasicShapeCircleClass, | 136 BasicShapeCircleClass, |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 return false; | 263 return false; |
| 262 return first->equals(*second); | 264 return first->equals(*second); |
| 263 } | 265 } |
| 264 | 266 |
| 265 #define DEFINE_CSS_VALUE_TYPE_CASTS(thisType, predicate) \ | 267 #define DEFINE_CSS_VALUE_TYPE_CASTS(thisType, predicate) \ |
| 266 DEFINE_TYPE_CASTS(thisType, CSSValue, value, value->predicate, value.predica
te) | 268 DEFINE_TYPE_CASTS(thisType, CSSValue, value, value->predicate, value.predica
te) |
| 267 | 269 |
| 268 } // namespace blink | 270 } // namespace blink |
| 269 | 271 |
| 270 #endif // CSSValue_h | 272 #endif // CSSValue_h |
| OLD | NEW |