| Index: third_party/WebKit/Source/core/style/ComputedStyle.h
|
| diff --git a/third_party/WebKit/Source/core/style/ComputedStyle.h b/third_party/WebKit/Source/core/style/ComputedStyle.h
|
| index 840807efafc28841032b7312a96c91a507dffabf..10b4d7b92000f500531fc0eb25548b22ebec2c48 100644
|
| --- a/third_party/WebKit/Source/core/style/ComputedStyle.h
|
| +++ b/third_party/WebKit/Source/core/style/ComputedStyle.h
|
| @@ -200,6 +200,20 @@ class CORE_EXPORT ComputedStyle : public ComputedStyleBase,
|
|
|
| DataRef<SVGComputedStyle> svg_style_;
|
|
|
| + // !START SYNC!: Keep this in sync with the copy constructor in
|
| + // ComputedStyle.cpp.
|
| +
|
| + // don't inherit
|
| + struct NonInheritedData {
|
| + NonInheritedData() : m_hasRemUnits(false), m_hasViewportUnits(false) {}
|
| +
|
| + // These are set if we used viewport or rem units when resolving a length.
|
| + unsigned m_hasRemUnits : 1;
|
| + unsigned m_hasViewportUnits : 1;
|
| + } m_nonInheritedData;
|
| +
|
| + // !END SYNC!
|
| +
|
| private:
|
| // TODO(sashab): Move these private members to the bottom of ComputedStyle.
|
| ALWAYS_INLINE ComputedStyle();
|
| @@ -2305,6 +2319,19 @@ class CORE_EXPORT ComputedStyle : public ComputedStyleBase,
|
| void AddCallbackSelector(const String& selector);
|
|
|
| // Non-property flags.
|
| + bool HasViewportUnits() const {
|
| + return m_nonInheritedData.m_hasViewportUnits;
|
| + }
|
| + // TODO(shend): This function should take no arguments.
|
| + void SetHasViewportUnits(bool hasViewportUnits) {
|
| + m_nonInheritedData.m_hasViewportUnits = hasViewportUnits;
|
| + }
|
| +
|
| + bool HasRemUnits() const { return m_nonInheritedData.m_hasRemUnits; }
|
| + void SetHasRemUnits() {
|
| + m_nonInheritedData.m_hasRemUnits = static_cast<unsigned>(true);
|
| + }
|
| +
|
| bool EmptyState() const { return EmptyStateInternal(); }
|
| void SetEmptyState(bool b) {
|
| SetUnique();
|
|
|