| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006 Rob Buis <buis@kde.org> | 2 * Copyright (C) 2006 Rob Buis <buis@kde.org> |
| 3 * (C) 2008 Nikolas Zimmermann <zimmermann@kde.org> | 3 * (C) 2008 Nikolas Zimmermann <zimmermann@kde.org> |
| 4 * Copyright (C) 2008 Apple Inc. All rights reserved. | 4 * Copyright (C) 2008 Apple Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 #include "core/svg/SVGURIReference.h" | 35 #include "core/svg/SVGURIReference.h" |
| 36 #include "wtf/MathExtras.h" | 36 #include "wtf/MathExtras.h" |
| 37 #include "wtf/text/StringBuilder.h" | 37 #include "wtf/text/StringBuilder.h" |
| 38 #include "wtf/text/WTFString.h" | 38 #include "wtf/text/WTFString.h" |
| 39 | 39 |
| 40 namespace WebCore { | 40 namespace WebCore { |
| 41 | 41 |
| 42 static inline SVGCursorElement* resourceReferencedByCursorElement(const String&
url, Document& document) | 42 static inline SVGCursorElement* resourceReferencedByCursorElement(const String&
url, Document& document) |
| 43 { | 43 { |
| 44 Element* element = SVGURIReference::targetElementFromIRIString(url, document
); | 44 Element* element = SVGURIReference::targetElementFromIRIString(url, document
); |
| 45 if (element && element->hasTagName(SVGNames::cursorTag)) | 45 return isSVGCursorElement(element) ? toSVGCursorElement(element) : 0; |
| 46 return toSVGCursorElement(element); | |
| 47 | |
| 48 return 0; | |
| 49 } | 46 } |
| 50 | 47 |
| 51 CSSCursorImageValue::CSSCursorImageValue(PassRefPtrWillBeRawPtr<CSSValue> imageV
alue, bool hasHotSpot, const IntPoint& hotSpot) | 48 CSSCursorImageValue::CSSCursorImageValue(PassRefPtrWillBeRawPtr<CSSValue> imageV
alue, bool hasHotSpot, const IntPoint& hotSpot) |
| 52 : CSSValue(CursorImageClass) | 49 : CSSValue(CursorImageClass) |
| 53 , m_imageValue(imageValue) | 50 , m_imageValue(imageValue) |
| 54 , m_hasHotSpot(hasHotSpot) | 51 , m_hasHotSpot(hasHotSpot) |
| 55 , m_hotSpot(hotSpot) | 52 , m_hotSpot(hotSpot) |
| 56 , m_accessedImage(false) | 53 , m_accessedImage(false) |
| 57 { | 54 { |
| 58 } | 55 } |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 195 return m_hasHotSpot ? other.m_hasHotSpot && m_hotSpot == other.m_hotSpot : !
other.m_hasHotSpot | 192 return m_hasHotSpot ? other.m_hasHotSpot && m_hotSpot == other.m_hotSpot : !
other.m_hasHotSpot |
| 196 && compareCSSValuePtr(m_imageValue, other.m_imageValue); | 193 && compareCSSValuePtr(m_imageValue, other.m_imageValue); |
| 197 } | 194 } |
| 198 | 195 |
| 199 void CSSCursorImageValue::traceAfterDispatch(Visitor* visitor) | 196 void CSSCursorImageValue::traceAfterDispatch(Visitor* visitor) |
| 200 { | 197 { |
| 201 CSSValue::traceAfterDispatch(visitor); | 198 CSSValue::traceAfterDispatch(visitor); |
| 202 } | 199 } |
| 203 | 200 |
| 204 } // namespace WebCore | 201 } // namespace WebCore |
| OLD | NEW |