Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(245)

Unified Diff: third_party/WebKit/Source/core/css/parser/CSSLazyParsingState.cpp

Issue 2671173002: Change CSSParserContext to have a Document handle (vs UseCounter). (Closed)
Patch Set: fix todo style Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/css/parser/CSSLazyParsingState.cpp
diff --git a/third_party/WebKit/Source/core/css/parser/CSSLazyParsingState.cpp b/third_party/WebKit/Source/core/css/parser/CSSLazyParsingState.cpp
index c5ed81cc30a8bbd6fa11196056f1df49ca57964b..43ab1914b8f3ed632c66329a0a9067c051ee5dc9 100644
--- a/third_party/WebKit/Source/core/css/parser/CSSLazyParsingState.cpp
+++ b/third_party/WebKit/Source/core/css/parser/CSSLazyParsingState.cpp
@@ -45,9 +45,8 @@ const CSSParserContext* CSSLazyParsingState::context() {
if (!m_document)
m_document = m_owningContents->anyOwnerDocument();
- UseCounter* useCounter = UseCounter::getFrom(m_document);
- if (useCounter != m_context->useCounter())
- m_context = CSSParserContext::create(m_context, useCounter);
+ if (!m_context->isDocumentHandleEqual(m_document))
+ m_context = CSSParserContext::create(m_context, m_document);
return m_context;
}

Powered by Google App Engine
This is Rietveld 408576698