| Index: third_party/WebKit/Source/core/animation/InterpolationEnvironment.h
|
| diff --git a/third_party/WebKit/Source/core/animation/InterpolationEnvironment.h b/third_party/WebKit/Source/core/animation/InterpolationEnvironment.h
|
| index b89c91a228f9e647e734296c3141a757e8b873cf..ea8e2bdcf149db5acdb20116f8865fc0e289eb5b 100644
|
| --- a/third_party/WebKit/Source/core/animation/InterpolationEnvironment.h
|
| +++ b/third_party/WebKit/Source/core/animation/InterpolationEnvironment.h
|
| @@ -10,6 +10,7 @@
|
|
|
| namespace blink {
|
|
|
| +class ComputedStyle;
|
| class StyleResolverState;
|
| class SVGPropertyBase;
|
| class SVGElement;
|
| @@ -17,28 +18,36 @@ class SVGElement;
|
| class InterpolationEnvironment {
|
| STACK_ALLOCATED();
|
| public:
|
| - explicit InterpolationEnvironment(StyleResolverState& state)
|
| - : m_state(&state)
|
| + explicit InterpolationEnvironment(const ComputedStyle& style)
|
| + : m_state(nullptr)
|
| + , m_style(&style)
|
| , m_svgElement(nullptr)
|
| , m_svgBaseValue(nullptr)
|
| { }
|
|
|
| + explicit InterpolationEnvironment(StyleResolverState&);
|
| +
|
| explicit InterpolationEnvironment(SVGElement& svgElement, const SVGPropertyBase& svgBaseValue)
|
| : m_state(nullptr)
|
| + , m_style(nullptr)
|
| , m_svgElement(&svgElement)
|
| , m_svgBaseValue(&svgBaseValue)
|
| { }
|
|
|
| - StyleResolverState& state() { ASSERT(m_state); return *m_state; }
|
| - const StyleResolverState& state() const { ASSERT(m_state); return *m_state; }
|
| + StyleResolverState& state() { DCHECK(m_state); return *m_state; }
|
| + const StyleResolverState& state() const { DCHECK(m_state); return *m_state; }
|
| +
|
| + ComputedStyle& style();
|
| + const ComputedStyle& style() const { DCHECK(m_style); return *m_style; }
|
|
|
| - SVGElement& svgElement() { ASSERT(m_svgElement); return *m_svgElement; }
|
| - const SVGElement& svgElement() const { ASSERT(m_svgElement); return *m_svgElement; }
|
| + SVGElement& svgElement() { DCHECK(m_svgElement); return *m_svgElement; }
|
| + const SVGElement& svgElement() const { DCHECK(m_svgElement); return *m_svgElement; }
|
|
|
| - const SVGPropertyBase& svgBaseValue() const { ASSERT(m_svgBaseValue); return *m_svgBaseValue; }
|
| + const SVGPropertyBase& svgBaseValue() const { DCHECK(m_svgBaseValue); return *m_svgBaseValue; }
|
|
|
| private:
|
| StyleResolverState* m_state;
|
| + const ComputedStyle* m_style;
|
| Member<SVGElement> m_svgElement;
|
| Member<const SVGPropertyBase> m_svgBaseValue;
|
| };
|
|
|