| 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 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 | 95 |
| 96 String preferredStylesheetSetName() const { return m_preferredStylesheetSetN
ame; } | 96 String preferredStylesheetSetName() const { return m_preferredStylesheetSetN
ame; } |
| 97 String selectedStylesheetSetName() const { return m_selectedStylesheetSetNam
e; } | 97 String selectedStylesheetSetName() const { return m_selectedStylesheetSetNam
e; } |
| 98 void setPreferredStylesheetSetNameIfNotSet(const String&); | 98 void setPreferredStylesheetSetNameIfNotSet(const String&); |
| 99 void setSelectedStylesheetSetName(const String&); | 99 void setSelectedStylesheetSetName(const String&); |
| 100 void setHttpDefaultStyle(const String&); | 100 void setHttpDefaultStyle(const String&); |
| 101 | 101 |
| 102 void addPendingSheet(StyleEngineContext&); | 102 void addPendingSheet(StyleEngineContext&); |
| 103 void removePendingSheet(Node* styleSheetCandidateNode, const StyleEngineCont
ext&); | 103 void removePendingSheet(Node* styleSheetCandidateNode, const StyleEngineCont
ext&); |
| 104 | 104 |
| 105 bool hasPendingSheets() const { return m_pendingStylesheets > 0; } | 105 bool hasPendingScriptBlockingSheets() const { return m_pendingScriptBlocking
Stylesheets > 0; } |
| 106 bool hasPendingRenderBlockingSheets() const { return m_pendingRenderBlocking
Stylesheets > 0; } | 106 bool hasPendingRenderBlockingSheets() const { return m_pendingRenderBlocking
Stylesheets > 0; } |
| 107 bool haveStylesheetsLoaded() const { return !hasPendingSheets() || m_ignoreP
endingStylesheets; } | 107 bool haveScriptBlockingStylesheetsLoaded() const { return !hasPendingScriptB
lockingSheets() || m_ignorePendingStylesheets; } |
| 108 bool haveRenderBlockingStylesheetsLoaded() const { return !hasPendingRenderB
lockingSheets() || m_ignorePendingStylesheets; } | 108 bool haveRenderBlockingStylesheetsLoaded() const { return !hasPendingRenderB
lockingSheets() || m_ignorePendingStylesheets; } |
| 109 bool ignoringPendingStylesheets() const { return m_ignorePendingStylesheets;
} | 109 bool ignoringPendingStylesheets() const { return m_ignorePendingStylesheets;
} |
| 110 | 110 |
| 111 unsigned maxDirectAdjacentSelectors() const { return m_maxDirectAdjacentSele
ctors; } | 111 unsigned maxDirectAdjacentSelectors() const { return m_maxDirectAdjacentSele
ctors; } |
| 112 bool usesSiblingRules() const { return m_usesSiblingRules; } | 112 bool usesSiblingRules() const { return m_usesSiblingRules; } |
| 113 bool usesFirstLineRules() const { return m_usesFirstLineRules; } | 113 bool usesFirstLineRules() const { return m_usesFirstLineRules; } |
| 114 bool usesWindowInactiveSelector() const { return m_usesWindowInactiveSelecto
r; } | 114 bool usesWindowInactiveSelector() const { return m_usesWindowInactiveSelecto
r; } |
| 115 | 115 |
| 116 bool usesRemUnits() const { return m_usesRemUnits; } | 116 bool usesRemUnits() const { return m_usesRemUnits; } |
| 117 void setUsesRemUnit(bool b) { m_usesRemUnits = b; } | 117 void setUsesRemUnit(bool b) { m_usesRemUnits = b; } |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 218 | 218 |
| 219 bool shouldSkipInvalidationFor(const Element&) const; | 219 bool shouldSkipInvalidationFor(const Element&) const; |
| 220 | 220 |
| 221 Member<Document> m_document; | 221 Member<Document> m_document; |
| 222 bool m_isMaster; | 222 bool m_isMaster; |
| 223 | 223 |
| 224 // Track the number of currently loading top-level stylesheets needed for la
yout. | 224 // Track the number of currently loading top-level stylesheets needed for la
yout. |
| 225 // Sheets loaded using the @import directive are not included in this count. | 225 // Sheets loaded using the @import directive are not included in this count. |
| 226 // We use this count of pending sheets to detect when we can begin attaching | 226 // We use this count of pending sheets to detect when we can begin attaching |
| 227 // elements and when it is safe to execute scripts. | 227 // elements and when it is safe to execute scripts. |
| 228 int m_pendingStylesheets = 0; | 228 int m_pendingScriptBlockingStylesheets = 0; |
| 229 int m_pendingRenderBlockingStylesheets = 0; | 229 int m_pendingRenderBlockingStylesheets = 0; |
| 230 | 230 |
| 231 HeapVector<Member<CSSStyleSheet>> m_injectedAuthorStyleSheets; | 231 HeapVector<Member<CSSStyleSheet>> m_injectedAuthorStyleSheets; |
| 232 | 232 |
| 233 Member<DocumentStyleSheetCollection> m_documentStyleSheetCollection; | 233 Member<DocumentStyleSheetCollection> m_documentStyleSheetCollection; |
| 234 | 234 |
| 235 typedef HeapHashMap<WeakMember<TreeScope>, Member<ShadowTreeStyleSheetCollec
tion>> StyleSheetCollectionMap; | 235 typedef HeapHashMap<WeakMember<TreeScope>, Member<ShadowTreeStyleSheetCollec
tion>> StyleSheetCollectionMap; |
| 236 StyleSheetCollectionMap m_styleSheetCollectionMap; | 236 StyleSheetCollectionMap m_styleSheetCollectionMap; |
| 237 | 237 |
| 238 bool m_documentScopeDirty = true; | 238 bool m_documentScopeDirty = true; |
| (...skipping 22 matching lines...) Expand all Loading... |
| 261 | 261 |
| 262 OwnPtr<StyleResolverStats> m_styleResolverStats; | 262 OwnPtr<StyleResolverStats> m_styleResolverStats; |
| 263 unsigned m_styleForElementCount = 0; | 263 unsigned m_styleForElementCount = 0; |
| 264 | 264 |
| 265 friend class StyleEngineTest; | 265 friend class StyleEngineTest; |
| 266 }; | 266 }; |
| 267 | 267 |
| 268 } // namespace blink | 268 } // namespace blink |
| 269 | 269 |
| 270 #endif | 270 #endif |
| OLD | NEW |