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) 2013 Google Inc. All rights reserved. | 9 * Copyright (C) 2013 Google Inc. All rights reserved. |
10 * | 10 * |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 | 169 |
170 void TreeScopeStyleSheetCollection::clearMediaQueryRuleSetStyleSheets() | 170 void TreeScopeStyleSheetCollection::clearMediaQueryRuleSetStyleSheets() |
171 { | 171 { |
172 for (size_t i = 0; i < m_activeAuthorStyleSheets.size(); ++i) { | 172 for (size_t i = 0; i < m_activeAuthorStyleSheets.size(); ++i) { |
173 StyleSheetContents* contents = m_activeAuthorStyleSheets[i]->contents(); | 173 StyleSheetContents* contents = m_activeAuthorStyleSheets[i]->contents(); |
174 if (contents->hasMediaQueries()) | 174 if (contents->hasMediaQueries()) |
175 contents->clearRuleSet(); | 175 contents->clearRuleSet(); |
176 } | 176 } |
177 } | 177 } |
178 | 178 |
179 void TreeScopeStyleSheetCollection::enableExitTransitionStylesheets() | 179 void TreeScopeStyleSheetCollection::setExitTransitionStyleshetsEnabled(bool enab
led) |
180 { | 180 { |
181 DocumentOrderedList::iterator begin = m_styleSheetCandidateNodes.begin(); | 181 DocumentOrderedList::iterator begin = m_styleSheetCandidateNodes.begin(); |
182 DocumentOrderedList::iterator end = m_styleSheetCandidateNodes.end(); | 182 DocumentOrderedList::iterator end = m_styleSheetCandidateNodes.end(); |
183 for (DocumentOrderedList::iterator it = begin; it != end; ++it) { | 183 for (DocumentOrderedList::iterator it = begin; it != end; ++it) { |
184 Node* node = *it; | 184 Node* node = *it; |
185 if (isHTMLLinkElement(*node)) | 185 if (isHTMLLinkElement(*node)) |
186 toHTMLLinkElement(node)->enableIfExitTransitionStyle(); | 186 toHTMLLinkElement(node)->setEnabledIfExitTransitionStyle(enabled); |
187 } | 187 } |
188 } | 188 } |
189 | 189 |
190 static bool styleSheetsUseRemUnits(const WillBeHeapVector<RefPtrWillBeMember<CSS
StyleSheet> >& sheets) | 190 static bool styleSheetsUseRemUnits(const WillBeHeapVector<RefPtrWillBeMember<CSS
StyleSheet> >& sheets) |
191 { | 191 { |
192 for (unsigned i = 0; i < sheets.size(); ++i) { | 192 for (unsigned i = 0; i < sheets.size(); ++i) { |
193 if (sheets[i]->contents()->usesRemUnits()) | 193 if (sheets[i]->contents()->usesRemUnits()) |
194 return true; | 194 return true; |
195 } | 195 } |
196 return false; | 196 return false; |
197 } | 197 } |
198 | 198 |
199 void TreeScopeStyleSheetCollection::updateUsesRemUnits() | 199 void TreeScopeStyleSheetCollection::updateUsesRemUnits() |
200 { | 200 { |
201 m_usesRemUnits = styleSheetsUseRemUnits(m_activeAuthorStyleSheets); | 201 m_usesRemUnits = styleSheetsUseRemUnits(m_activeAuthorStyleSheets); |
202 } | 202 } |
203 | 203 |
204 void TreeScopeStyleSheetCollection::trace(Visitor* visitor) | 204 void TreeScopeStyleSheetCollection::trace(Visitor* visitor) |
205 { | 205 { |
206 visitor->trace(m_treeScope); | 206 visitor->trace(m_treeScope); |
207 visitor->trace(m_styleSheetCandidateNodes); | 207 visitor->trace(m_styleSheetCandidateNodes); |
208 StyleSheetCollection::trace(visitor); | 208 StyleSheetCollection::trace(visitor); |
209 } | 209 } |
210 | 210 |
211 } | 211 } |
OLD | NEW |