| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CSSStyleImageValue_h | 5 #ifndef CSSStyleImageValue_h |
| 6 #define CSSStyleImageValue_h | 6 #define CSSStyleImageValue_h |
| 7 | 7 |
| 8 #include "core/css/CSSImageValue.h" | 8 #include "core/css/CSSImageValue.h" |
| 9 #include "core/css/cssom/CSSResourceValue.h" | 9 #include "core/css/cssom/CSSResourceValue.h" |
| 10 #include "core/fetch/ImageResource.h" | 10 #include "core/fetch/ImageResource.h" |
| 11 #include "core/style/StyleImage.h" | 11 #include "core/style/StyleImage.h" |
| 12 | 12 |
| 13 | 13 |
| 14 namespace blink { | 14 namespace blink { |
| 15 namespace cssom { |
| 15 | 16 |
| 16 class CORE_EXPORT CSSStyleImageValue : public CSSResourceValue { | 17 class CORE_EXPORT CSSStyleImageValue : public CSSResourceValue { |
| 17 WTF_MAKE_NONCOPYABLE(CSSStyleImageValue); | 18 WTF_MAKE_NONCOPYABLE(CSSStyleImageValue); |
| 18 DEFINE_WRAPPERTYPEINFO(); | 19 DEFINE_WRAPPERTYPEINFO(); |
| 19 public: | 20 public: |
| 20 virtual ~CSSStyleImageValue() { } | 21 virtual ~CSSStyleImageValue() { } |
| 21 | 22 |
| 22 StyleValueType type() const override { return ImageType; } | 23 StyleValueType type() const override { return ImageType; } |
| 23 | 24 |
| 24 double intrinsicWidth(bool& isNull); | 25 double intrinsicWidth(bool& isNull); |
| (...skipping 24 matching lines...) Expand all Loading... |
| 49 virtual bool isCachePending() const { return m_imageValue->isCachePending();
} | 50 virtual bool isCachePending() const { return m_imageValue->isCachePending();
} |
| 50 | 51 |
| 51 Resource::Status status() const override | 52 Resource::Status status() const override |
| 52 { | 53 { |
| 53 if (isCachePending()) | 54 if (isCachePending()) |
| 54 return Resource::Status::NotStarted; | 55 return Resource::Status::NotStarted; |
| 55 return m_imageValue->cachedImage()->cachedImage()->getStatus(); | 56 return m_imageValue->cachedImage()->cachedImage()->getStatus(); |
| 56 } | 57 } |
| 57 }; | 58 }; |
| 58 | 59 |
| 60 } // namespace cssom |
| 59 } // namespace blink | 61 } // namespace blink |
| 60 | 62 |
| 63 |
| 61 #endif // CSSResourceValue_h | 64 #endif // CSSResourceValue_h |
| OLD | NEW |