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

Side by Side Diff: Source/core/css/CSSToStyleMap.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 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 unified diff | Download patch
« no previous file with comments | « Source/core/css/CSSToLengthConversionData.cpp ('k') | Source/core/css/CSSToStyleMap.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 3 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
4 * Copyright (C) 2012 Google Inc. All rights reserved. 4 * Copyright (C) 2012 Google Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 11 matching lines...) Expand all
22 #ifndef CSSToStyleMap_h 22 #ifndef CSSToStyleMap_h
23 #define CSSToStyleMap_h 23 #define CSSToStyleMap_h
24 24
25 #include "CSSPropertyNames.h" 25 #include "CSSPropertyNames.h"
26 #include "core/css/resolver/ElementStyleResources.h" 26 #include "core/css/resolver/ElementStyleResources.h"
27 #include "wtf/Noncopyable.h" 27 #include "wtf/Noncopyable.h"
28 28
29 namespace WebCore { 29 namespace WebCore {
30 30
31 class FillLayer; 31 class FillLayer;
32 class CSSAnimationData;
33 class CSSToLengthConversionData;
32 class CSSValue; 34 class CSSValue;
33 class CSSAnimationData;
34 class RenderStyle; 35 class RenderStyle;
35 class StyleImage; 36 class StyleImage;
36 class StyleResolverState; 37 class StyleResolverState;
37 class NinePieceImage; 38 class NinePieceImage;
38 class BorderImageLengthBox; 39 class BorderImageLengthBox;
39 40
40 // CSSToStyleMap is a short-lived helper object which 41 // CSSToStyleMap is a short-lived helper object which
41 // given the current StyleResolverState can map 42 // given the current StyleResolverState can map
42 // CSSValue objects into their RenderStyle equivalents. 43 // CSSValue objects into their RenderStyle equivalents.
43 44
(...skipping 24 matching lines...) Expand all
68 void mapAnimationPlayState(CSSAnimationData*, CSSValue*) const; 69 void mapAnimationPlayState(CSSAnimationData*, CSSValue*) const;
69 void mapAnimationProperty(CSSAnimationData*, CSSValue*) const; 70 void mapAnimationProperty(CSSAnimationData*, CSSValue*) const;
70 void mapAnimationTimingFunction(CSSAnimationData*, CSSValue*) const; 71 void mapAnimationTimingFunction(CSSAnimationData*, CSSValue*) const;
71 72
72 void mapNinePieceImage(RenderStyle* mutableStyle, CSSPropertyID, CSSValue*, NinePieceImage&); 73 void mapNinePieceImage(RenderStyle* mutableStyle, CSSPropertyID, CSSValue*, NinePieceImage&);
73 void mapNinePieceImageSlice(CSSValue*, NinePieceImage&) const; 74 void mapNinePieceImageSlice(CSSValue*, NinePieceImage&) const;
74 BorderImageLengthBox mapNinePieceImageQuad(CSSValue*) const; 75 BorderImageLengthBox mapNinePieceImageQuad(CSSValue*) const;
75 void mapNinePieceImageRepeat(CSSValue*, NinePieceImage&) const; 76 void mapNinePieceImageRepeat(CSSValue*, NinePieceImage&) const;
76 77
77 private: 78 private:
78 const RenderStyle* style() const; 79 const CSSToLengthConversionData& cssToLengthConversionData() const;
79 const RenderStyle* rootElementStyle() const;
80 bool useSVGZoomRules() const; 80 bool useSVGZoomRules() const;
81 81
82 PassRefPtr<StyleImage> styleImage(CSSPropertyID, CSSValue*); 82 PassRefPtr<StyleImage> styleImage(CSSPropertyID, CSSValue*);
83 83
84 // FIXME: Consider passing a StyleResolverState (or ElementResolveState) 84 // FIXME: Consider passing a StyleResolverState (or ElementResolveState)
85 // as an argument instead of caching it on this object. 85 // as an argument instead of caching it on this object.
86 const StyleResolverState& m_state; 86 const StyleResolverState& m_state;
87 ElementStyleResources& m_elementStyleResources; 87 ElementStyleResources& m_elementStyleResources;
88 }; 88 };
89 89
90 } 90 }
91 91
92 #endif 92 #endif
OLDNEW
« no previous file with comments | « Source/core/css/CSSToLengthConversionData.cpp ('k') | Source/core/css/CSSToStyleMap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698