OLD | NEW |
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. | 3 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. |
4 * All rights reserved. | 4 * 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 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 | 74 |
75 public: | 75 public: |
76 static StyleResolver* create(Document& document) { | 76 static StyleResolver* create(Document& document) { |
77 return new StyleResolver(document); | 77 return new StyleResolver(document); |
78 } | 78 } |
79 ~StyleResolver(); | 79 ~StyleResolver(); |
80 void dispose(); | 80 void dispose(); |
81 | 81 |
82 PassRefPtr<ComputedStyle> styleForElement( | 82 PassRefPtr<ComputedStyle> styleForElement( |
83 Element*, | 83 Element*, |
84 const ComputedStyle* parentStyle = 0, | 84 const ComputedStyle* parentStyle = nullptr, |
| 85 const ComputedStyle* layoutParentStyle = nullptr, |
85 StyleSharingBehavior = AllowStyleSharing, | 86 StyleSharingBehavior = AllowStyleSharing, |
86 RuleMatchingBehavior = MatchAllRules); | 87 RuleMatchingBehavior = MatchAllRules); |
87 | 88 |
88 static PassRefPtr<AnimatableValue> createAnimatableValueSnapshot( | 89 static PassRefPtr<AnimatableValue> createAnimatableValueSnapshot( |
89 Element&, | 90 Element&, |
90 const ComputedStyle& baseStyle, | 91 const ComputedStyle& baseStyle, |
91 const ComputedStyle* parentStyle, | 92 const ComputedStyle* parentStyle, |
92 CSSPropertyID, | 93 CSSPropertyID, |
93 const CSSValue*); | 94 const CSSValue*); |
94 | 95 |
95 PassRefPtr<ComputedStyle> pseudoStyleForElement( | 96 PassRefPtr<ComputedStyle> pseudoStyleForElement( |
96 Element*, | 97 Element*, |
97 const PseudoStyleRequest&, | 98 const PseudoStyleRequest&, |
98 const ComputedStyle* parentStyle); | 99 const ComputedStyle* parentStyle, |
| 100 const ComputedStyle* layoutParentStyle); |
99 | 101 |
100 PassRefPtr<ComputedStyle> styleForPage(int pageIndex); | 102 PassRefPtr<ComputedStyle> styleForPage(int pageIndex); |
101 PassRefPtr<ComputedStyle> styleForText(Text*); | 103 PassRefPtr<ComputedStyle> styleForText(Text*); |
102 | 104 |
103 static PassRefPtr<ComputedStyle> styleForDocument(Document&); | 105 static PassRefPtr<ComputedStyle> styleForDocument(Document&); |
104 | 106 |
105 // TODO(esprehn): StyleResolver should probably not contain tree walking | 107 // TODO(esprehn): StyleResolver should probably not contain tree walking |
106 // state, instead we should pass a context object during recalcStyle. | 108 // state, instead we should pass a context object during recalcStyle. |
107 SelectorFilter& selectorFilter() { return m_selectorFilter; } | 109 SelectorFilter& selectorFilter() { return m_selectorFilter; } |
108 | 110 |
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
314 bool m_wasViewportResized = false; | 316 bool m_wasViewportResized = false; |
315 | 317 |
316 unsigned m_styleSharingDepth = 0; | 318 unsigned m_styleSharingDepth = 0; |
317 HeapVector<Member<StyleSharingList>, styleSharingMaxDepth> | 319 HeapVector<Member<StyleSharingList>, styleSharingMaxDepth> |
318 m_styleSharingLists; | 320 m_styleSharingLists; |
319 }; | 321 }; |
320 | 322 |
321 } // namespace blink | 323 } // namespace blink |
322 | 324 |
323 #endif // StyleResolver_h | 325 #endif // StyleResolver_h |
OLD | NEW |