| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All r
ights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All r
ights reserved. |
| 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 8 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 8 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 9 * Copyright (C) 2011 Google Inc. All rights reserved. | 9 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 10 * | 10 * |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 virtual void fontsNeedUpdate(CSSFontSelector*) override; | 127 virtual void fontsNeedUpdate(CSSFontSelector*) override; |
| 128 | 128 |
| 129 private: | 129 private: |
| 130 StyleEngine(Document&); | 130 StyleEngine(Document&); |
| 131 | 131 |
| 132 StyleSheetCollection* ensureStyleSheetCollectionFor(TreeScope&); | 132 StyleSheetCollection* ensureStyleSheetCollectionFor(TreeScope&); |
| 133 StyleSheetCollection* styleSheetCollectionFor(TreeScope&); | 133 StyleSheetCollection* styleSheetCollectionFor(TreeScope&); |
| 134 | 134 |
| 135 void markTreeScopeDirty(TreeScope&); | 135 void markTreeScopeDirty(TreeScope&); |
| 136 | 136 |
| 137 typedef ListHashSet<TreeScope*, 16> TreeScopeSet; | |
| 138 static void insertTreeScopeInDocumentOrder(TreeScopeSet&, TreeScope*); | |
| 139 | |
| 140 void createResolver(); | 137 void createResolver(); |
| 141 | 138 |
| 142 const StyleSheetCollection* documentStyleSheetCollection() const | 139 const StyleSheetCollection* documentStyleSheetCollection() const |
| 143 { | 140 { |
| 144 return m_documentStyleSheetCollection.get(); | 141 return m_documentStyleSheetCollection.get(); |
| 145 } | 142 } |
| 146 | 143 |
| 147 StyleSheetCollection* documentStyleSheetCollection() | 144 StyleSheetCollection* documentStyleSheetCollection() |
| 148 { | 145 { |
| 149 return m_documentStyleSheetCollection.get(); | 146 return m_documentStyleSheetCollection.get(); |
| 150 } | 147 } |
| 151 | 148 |
| 152 RawPtr<Document> m_document; | 149 RawPtr<Document> m_document; |
| 153 | 150 |
| 154 // TODO(esprehn): Remove special separate collection for document. | 151 // TODO(esprehn): Remove special separate collection for document. |
| 155 OwnPtr<StyleSheetCollection> m_documentStyleSheetCollection; | 152 OwnPtr<StyleSheetCollection> m_documentStyleSheetCollection; |
| 156 | 153 |
| 157 typedef HashMap<RawPtr<TreeScope>, OwnPtr<StyleSheetCollection> > StyleSheet
CollectionMap; | 154 typedef HashMap<RawPtr<TreeScope>, OwnPtr<StyleSheetCollection> > StyleSheet
CollectionMap; |
| 158 StyleSheetCollectionMap m_styleSheetCollectionMap; | 155 StyleSheetCollectionMap m_styleSheetCollectionMap; |
| 159 typedef HashSet<RawPtr<const ScopedStyleResolver> > ScopedStyleResolverSet; | 156 typedef HashSet<RawPtr<const ScopedStyleResolver> > ScopedStyleResolverSet; |
| 160 ScopedStyleResolverSet m_scopedStyleResolvers; | 157 ScopedStyleResolverSet m_scopedStyleResolvers; |
| 161 | 158 |
| 159 typedef ListHashSet<TreeScope*, 16> TreeScopeSet; |
| 162 TreeScopeSet m_dirtyTreeScopes; | 160 TreeScopeSet m_dirtyTreeScopes; |
| 163 TreeScopeSet m_activeTreeScopes; | 161 TreeScopeSet m_activeTreeScopes; |
| 164 | 162 |
| 165 bool m_ignorePendingStylesheets; | 163 bool m_ignorePendingStylesheets; |
| 166 OwnPtr<StyleResolver> m_resolver; | 164 OwnPtr<StyleResolver> m_resolver; |
| 167 | 165 |
| 168 RefPtr<CSSFontSelector> m_fontSelector; | 166 RefPtr<CSSFontSelector> m_fontSelector; |
| 169 | 167 |
| 170 HashMap<AtomicString, RawPtr<StyleSheetContents> > m_textToSheetCache; | 168 HashMap<AtomicString, RawPtr<StyleSheetContents> > m_textToSheetCache; |
| 171 HashMap<RawPtr<StyleSheetContents>, AtomicString> m_sheetToTextCache; | 169 HashMap<RawPtr<StyleSheetContents>, AtomicString> m_sheetToTextCache; |
| 172 }; | 170 }; |
| 173 | 171 |
| 174 } | 172 } |
| 175 | 173 |
| 176 #endif // SKY_ENGINE_CORE_DOM_STYLEENGINE_H_ | 174 #endif // SKY_ENGINE_CORE_DOM_STYLEENGINE_H_ |
| OLD | NEW |