OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007 Rob Buis | 2 * Copyright (C) 2006, 2007 Rob Buis |
3 * Copyright (C) 2008 Apple, Inc. All rights reserved. | 3 * Copyright (C) 2008 Apple, Inc. All rights reserved. |
4 * | 4 * |
5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
9 * | 9 * |
10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 if (m_registeredAsCandidate) { | 99 if (m_registeredAsCandidate) { |
100 document.styleEngine().removeStyleSheetCandidateNode(element, shadowRoot
? *toTreeScope(shadowRoot) : toTreeScope(document)); | 100 document.styleEngine().removeStyleSheetCandidateNode(element, shadowRoot
? *toTreeScope(shadowRoot) : toTreeScope(document)); |
101 m_registeredAsCandidate = false; | 101 m_registeredAsCandidate = false; |
102 } | 102 } |
103 | 103 |
104 RefPtrWillBeRawPtr<StyleSheet> removedSheet = m_sheet.get(); | 104 RefPtrWillBeRawPtr<StyleSheet> removedSheet = m_sheet.get(); |
105 | 105 |
106 if (m_sheet) | 106 if (m_sheet) |
107 clearSheet(element); | 107 clearSheet(element); |
108 if (removedSheet) | 108 if (removedSheet) |
109 document.removedStyleSheet(removedSheet.get(), AnalyzedStyleUpdate); | 109 document.styleEngine().setNeedsActiveStyleUpdate(removedSheet.get(), Ana
lyzedStyleUpdate); |
110 } | 110 } |
111 | 111 |
112 void StyleElement::clearDocumentData(Document& document, Element* element) | 112 void StyleElement::clearDocumentData(Document& document, Element* element) |
113 { | 113 { |
114 if (m_sheet) | 114 if (m_sheet) |
115 m_sheet->clearOwnerNode(); | 115 m_sheet->clearOwnerNode(); |
116 | 116 |
117 if (m_registeredAsCandidate) { | 117 if (m_registeredAsCandidate) { |
118 ASSERT(element->inDocument()); | 118 ASSERT(element->inDocument()); |
119 document.styleEngine().removeStyleSheetCandidateNode(element, element->t
reeScope()); | 119 document.styleEngine().removeStyleSheetCandidateNode(element, element->t
reeScope()); |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
231 { | 231 { |
232 document.styleEngine().addPendingSheet(); | 232 document.styleEngine().addPendingSheet(); |
233 } | 233 } |
234 | 234 |
235 DEFINE_TRACE(StyleElement) | 235 DEFINE_TRACE(StyleElement) |
236 { | 236 { |
237 visitor->trace(m_sheet); | 237 visitor->trace(m_sheet); |
238 } | 238 } |
239 | 239 |
240 } // namespace blink | 240 } // namespace blink |
OLD | NEW |