| Index: third_party/WebKit/Source/core/css/parser/CSSParserImpl.h
|
| diff --git a/third_party/WebKit/Source/core/css/parser/CSSParserImpl.h b/third_party/WebKit/Source/core/css/parser/CSSParserImpl.h
|
| index 0bcd5153417d9830ee91dc5970255cdc3d5f1f2f..ec044025094c5f0e0fdd2d94b1db9d798d8ff82d 100644
|
| --- a/third_party/WebKit/Source/core/css/parser/CSSParserImpl.h
|
| +++ b/third_party/WebKit/Source/core/css/parser/CSSParserImpl.h
|
| @@ -40,7 +40,7 @@ class CSSParserImpl {
|
| STACK_ALLOCATED();
|
| WTF_MAKE_NONCOPYABLE(CSSParserImpl);
|
| public:
|
| - CSSParserImpl(const CSSParserContext&, StyleSheetContents* = nullptr);
|
| + CSSParserImpl(const CSSParserContext&, StyleSheetContents* = nullptr, bool deferPropertyParsing = false);
|
|
|
| enum AllowedRulesType {
|
| // As per css-syntax, css-cascade and css-namespaces, @charset rules
|
| @@ -62,7 +62,7 @@ public:
|
| static ImmutableStylePropertySet* parseInlineStyleDeclaration(const String&, Element*);
|
| static bool parseDeclarationList(MutableStylePropertySet*, const String&, const CSSParserContext&);
|
| static StyleRuleBase* parseRule(const String&, const CSSParserContext&, StyleSheetContents*, AllowedRulesType);
|
| - static void parseStyleSheet(const String&, const CSSParserContext&, StyleSheetContents*);
|
| + static void parseStyleSheet(const String&, const CSSParserContext&, StyleSheetContents*, bool deferPropertyParsing = false);
|
| static CSSSelectorList parsePageSelector(CSSParserTokenRange, StyleSheetContents*);
|
|
|
| static ImmutableStylePropertySet* parseCustomPropertySet(CSSParserTokenRange);
|
| @@ -111,6 +111,12 @@ private:
|
|
|
| static std::unique_ptr<Vector<double>> consumeKeyframeKeyList(CSSParserTokenRange);
|
|
|
| + static std::unique_ptr<DeferredPropertiesClosure> createDeferredPropertiesClosure(CSSParserTokenRange, const CSSParserContext&, UseCounter*);
|
| +
|
| + static StylePropertySet* parseDeclarationListForLazyStyle(Vector<CSSParserToken>, const CSSParserContext*, UseCounter*);
|
| +
|
| + static bool shouldLazilyParseProperties(const CSSSelectorList& selectors, CSSParserTokenRange);
|
| +
|
| // FIXME: Can we build StylePropertySets directly?
|
| // FIXME: Investigate using a smaller inline buffer
|
| HeapVector<CSSProperty, 256> m_parsedProperties;
|
| @@ -120,6 +126,8 @@ private:
|
|
|
| // For the inspector
|
| CSSParserObserverWrapper* m_observerWrapper;
|
| +
|
| + bool m_deferPropertyParsing = false;
|
| };
|
|
|
| } // namespace blink
|
|
|