| 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 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 static PassOwnPtr<StyleEngine> create(Document& document) { return adoptPtr(
new StyleEngine(document)); } | 54 static PassOwnPtr<StyleEngine> create(Document& document) { return adoptPtr(
new StyleEngine(document)); } |
| 55 | 55 |
| 56 ~StyleEngine(); | 56 ~StyleEngine(); |
| 57 | 57 |
| 58 const Vector<RefPtr<StyleSheet> >& styleSheetsForStyleSheetList(TreeScope&); | 58 const Vector<RefPtr<StyleSheet> >& styleSheetsForStyleSheetList(TreeScope&); |
| 59 const Vector<RefPtr<CSSStyleSheet> >& activeAuthorStyleSheets() const; | 59 const Vector<RefPtr<CSSStyleSheet> >& activeAuthorStyleSheets() const; |
| 60 | 60 |
| 61 CSSStyleSheet* pageUserSheet(); | 61 CSSStyleSheet* pageUserSheet(); |
| 62 const Vector<RefPtr<CSSStyleSheet> >& documentUserStyleSheets() const { retu
rn m_userStyleSheets; } | 62 const Vector<RefPtr<CSSStyleSheet> >& documentUserStyleSheets() const { retu
rn m_userStyleSheets; } |
| 63 const Vector<RefPtr<CSSStyleSheet> >& documentAuthorStyleSheets() const { re
turn m_authorStyleSheets; } | 63 const Vector<RefPtr<CSSStyleSheet> >& documentAuthorStyleSheets() const { re
turn m_authorStyleSheets; } |
| 64 const Vector<RefPtr<CSSStyleSheet> >& injectedUserStyleSheets() const; | |
| 65 const Vector<RefPtr<CSSStyleSheet> >& injectedAuthorStyleSheets() const; | 64 const Vector<RefPtr<CSSStyleSheet> >& injectedAuthorStyleSheets() const; |
| 66 | 65 |
| 67 void addStyleSheetCandidateNode(Node*, bool createdByParser); | 66 void addStyleSheetCandidateNode(Node*, bool createdByParser); |
| 68 void removeStyleSheetCandidateNode(Node*, ContainerNode* scopingNode = 0); | 67 void removeStyleSheetCandidateNode(Node*, ContainerNode* scopingNode = 0); |
| 69 void modifiedStyleSheetCandidateNode(Node*); | 68 void modifiedStyleSheetCandidateNode(Node*); |
| 70 | 69 |
| 71 void clearPageUserSheet(); | 70 void clearPageUserSheet(); |
| 72 void updatePageUserSheet(); | 71 void updatePageUserSheet(); |
| 73 void invalidateInjectedStyleSheetCache(); | 72 void invalidateInjectedStyleSheetCache(); |
| 74 void updateInjectedStyleSheetCache() const; | 73 void updateInjectedStyleSheetCache() const; |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 Document& m_document; | 124 Document& m_document; |
| 126 | 125 |
| 127 // Track the number of currently loading top-level stylesheets needed for re
ndering. | 126 // Track the number of currently loading top-level stylesheets needed for re
ndering. |
| 128 // Sheets loaded using the @import directive are not included in this count. | 127 // Sheets loaded using the @import directive are not included in this count. |
| 129 // We use this count of pending sheets to detect when we can begin attaching | 128 // We use this count of pending sheets to detect when we can begin attaching |
| 130 // elements and when it is safe to execute scripts. | 129 // elements and when it is safe to execute scripts. |
| 131 int m_pendingStylesheets; | 130 int m_pendingStylesheets; |
| 132 | 131 |
| 133 RefPtr<CSSStyleSheet> m_pageUserSheet; | 132 RefPtr<CSSStyleSheet> m_pageUserSheet; |
| 134 | 133 |
| 135 mutable Vector<RefPtr<CSSStyleSheet> > m_injectedUserStyleSheets; | |
| 136 mutable Vector<RefPtr<CSSStyleSheet> > m_injectedAuthorStyleSheets; | 134 mutable Vector<RefPtr<CSSStyleSheet> > m_injectedAuthorStyleSheets; |
| 137 mutable bool m_injectedStyleSheetCacheValid; | 135 mutable bool m_injectedStyleSheetCacheValid; |
| 138 | 136 |
| 139 Vector<RefPtr<CSSStyleSheet> > m_userStyleSheets; | 137 Vector<RefPtr<CSSStyleSheet> > m_userStyleSheets; |
| 140 Vector<RefPtr<CSSStyleSheet> > m_authorStyleSheets; | 138 Vector<RefPtr<CSSStyleSheet> > m_authorStyleSheets; |
| 141 | 139 |
| 142 bool m_needsUpdateActiveStylesheetsOnStyleRecalc; | 140 bool m_needsUpdateActiveStylesheetsOnStyleRecalc; |
| 143 | 141 |
| 144 DocumentStyleSheetCollection m_documentStyleSheetCollection; | 142 DocumentStyleSheetCollection m_documentStyleSheetCollection; |
| 145 HashMap<TreeScope*, OwnPtr<StyleSheetCollection> > m_styleSheetCollectionMap
; | 143 HashMap<TreeScope*, OwnPtr<StyleSheetCollection> > m_styleSheetCollectionMap
; |
| 146 | 144 |
| 147 TreeScopeSet m_dirtyTreeScopes; | 145 TreeScopeSet m_dirtyTreeScopes; |
| 148 TreeScopeSet m_activeTreeScopes; | 146 TreeScopeSet m_activeTreeScopes; |
| 149 bool m_needsDocumentStyleSheetsUpdate; | 147 bool m_needsDocumentStyleSheetsUpdate; |
| 150 | 148 |
| 151 String m_preferredStylesheetSetName; | 149 String m_preferredStylesheetSetName; |
| 152 String m_selectedStylesheetSetName; | 150 String m_selectedStylesheetSetName; |
| 153 | 151 |
| 154 bool m_usesSiblingRules; | 152 bool m_usesSiblingRules; |
| 155 bool m_usesSiblingRulesOverride; | 153 bool m_usesSiblingRulesOverride; |
| 156 bool m_usesFirstLineRules; | 154 bool m_usesFirstLineRules; |
| 157 bool m_usesFirstLetterRules; | 155 bool m_usesFirstLetterRules; |
| 158 bool m_usesRemUnits; | 156 bool m_usesRemUnits; |
| 159 }; | 157 }; |
| 160 | 158 |
| 161 } | 159 } |
| 162 | 160 |
| 163 #endif | 161 #endif |
| OLD | NEW |