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

Unified Diff: third_party/WebKit/Source/core/css/CSSVariableData.h

Issue 1498713002: Store custom property backing strings in resolved CSSVariableData objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/CSSVariableData.h
diff --git a/third_party/WebKit/Source/core/css/CSSVariableData.h b/third_party/WebKit/Source/core/css/CSSVariableData.h
index 9b350338e285513065ce3200fb5dc244ba6951cf..2bfe8265308a399215933874bd2387112af5bec4 100644
--- a/third_party/WebKit/Source/core/css/CSSVariableData.h
+++ b/third_party/WebKit/Source/core/css/CSSVariableData.h
@@ -23,9 +23,9 @@ public:
return adoptRef(new CSSVariableData(range, needsVariableResolution));
}
- static PassRefPtr<CSSVariableData> createResolved(const Vector<CSSParserToken>& resolvedTokens)
+ static PassRefPtr<CSSVariableData> createResolved(const Vector<CSSParserToken>& resolvedTokens, PassRefPtr<CSSVariableData> unresolvedData)
{
- return adoptRef(new CSSVariableData(resolvedTokens));
+ return adoptRef(new CSSVariableData(resolvedTokens, unresolvedData->m_backingString));
}
CSSParserTokenRange tokenRange() { return m_tokens; }
@@ -40,8 +40,9 @@ private:
// StylePropertySets contain references to CSSCustomPropertyDeclarations, which
// point to the unresolved CSSVariableData values that own the backing strings
// this will potentially reference.
alancutter (OOO until 2018) 2015/12/03 04:14:12 We should update the comment to the new lifetime g
shans 2015/12/03 04:29:55 This comment isn't wrong.. I think I'll submit (p
- CSSVariableData(const Vector<CSSParserToken>& resolvedTokens)
- : m_tokens(resolvedTokens)
+ CSSVariableData(const Vector<CSSParserToken>& resolvedTokens, String backingString)
+ : m_backingString(backingString)
+ , m_tokens(resolvedTokens)
, m_needsVariableResolution(false)
{ }
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698