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

Unified Diff: Source/core/css/resolver/StyleResolverState.h

Issue 64293008: Wrap CSS length conversion arguments in an object (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: don't make it noncopyable ; clang doesn't do the RVO stuffs? Created 7 years, 1 month 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 | « Source/core/css/resolver/StyleBuilderCustom.cpp ('k') | Source/core/css/resolver/StyleResolverState.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/resolver/StyleResolverState.h
diff --git a/Source/core/css/resolver/StyleResolverState.h b/Source/core/css/resolver/StyleResolverState.h
index cedd3a4dcaab08bd725beea82b06f5492644ee46..998cfc3fe231b3e58e354f3b5eb64d759785d306 100644
--- a/Source/core/css/resolver/StyleResolverState.h
+++ b/Source/core/css/resolver/StyleResolverState.h
@@ -26,6 +26,7 @@
#include "core/animation/css/CSSAnimations.h"
#include "core/css/CSSSVGDocumentValue.h"
+#include "core/css/CSSToLengthConversionData.h"
#include "core/css/CSSToStyleMap.h"
#include "core/css/resolver/ElementResolveContext.h"
#include "core/css/resolver/ElementStyleResources.h"
@@ -58,11 +59,13 @@ public:
const ElementResolveContext& elementContext() const { return m_elementContext; }
- void setStyle(PassRefPtr<RenderStyle> style) { m_style = style; }
+ void setStyle(PassRefPtr<RenderStyle> style) { m_style = style; m_cssToLengthConversionData.setStyle(m_style.get()); }
const RenderStyle* style() const { return m_style.get(); }
RenderStyle* style() { return m_style.get(); }
PassRefPtr<RenderStyle> takeStyle() { return m_style.release(); }
+ const CSSToLengthConversionData& cssToLengthConversionData() const { return m_cssToLengthConversionData; }
+
void setAnimationUpdate(PassOwnPtr<CSSAnimationUpdate> update) { m_animationUpdate = update; }
const CSSAnimationUpdate* animationUpdate() { return m_animationUpdate.get(); }
PassOwnPtr<CSSAnimationUpdate> takeAnimationUpdate() { return m_animationUpdate.release(); }
@@ -138,6 +141,8 @@ private:
// m_style is the primary output for each element's style resolve.
RefPtr<RenderStyle> m_style;
+ CSSToLengthConversionData m_cssToLengthConversionData;
+
// m_parentStyle is not always just element->parentNode()->style()
// so we keep it separate from m_elementContext.
RefPtr<RenderStyle> m_parentStyle;
« no previous file with comments | « Source/core/css/resolver/StyleBuilderCustom.cpp ('k') | Source/core/css/resolver/StyleResolverState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698