Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1060)

Side by Side Diff: Source/core/dom/StyleElement.cpp

Issue 192293002: Use new is*Element() helper functions in DOM code (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add is*Element(PassRefPtr) helper Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 78
79 document.removedStyleSheet(removedSheet.get(), RecalcStyleDeferred, Analyzed StyleUpdate); 79 document.removedStyleSheet(removedSheet.get(), RecalcStyleDeferred, Analyzed StyleUpdate);
80 } 80 }
81 81
82 void StyleElement::clearDocumentData(Document& document, Element* element) 82 void StyleElement::clearDocumentData(Document& document, Element* element)
83 { 83 {
84 if (m_sheet) 84 if (m_sheet)
85 m_sheet->clearOwnerNode(); 85 m_sheet->clearOwnerNode();
86 86
87 if (element->inDocument()) 87 if (element->inDocument())
88 document.styleEngine()->removeStyleSheetCandidateNode(element, element-> hasTagName(HTMLNames::styleTag) ? toHTMLStyleElement(element)->scopingNode() : 0); 88 document.styleEngine()->removeStyleSheetCandidateNode(element, isHTMLSty leElement(*element) ? toHTMLStyleElement(*element).scopingNode() : 0);
89 } 89 }
90 90
91 void StyleElement::childrenChanged(Element* element) 91 void StyleElement::childrenChanged(Element* element)
92 { 92 {
93 ASSERT(element); 93 ASSERT(element);
94 if (m_createdByParser) 94 if (m_createdByParser)
95 return; 95 return;
96 96
97 process(element); 97 process(element);
98 } 98 }
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 document.styleEngine()->removePendingSheet(m_sheet->ownerNode()); 165 document.styleEngine()->removePendingSheet(m_sheet->ownerNode());
166 return true; 166 return true;
167 } 167 }
168 168
169 void StyleElement::startLoadingDynamicSheet(Document& document) 169 void StyleElement::startLoadingDynamicSheet(Document& document)
170 { 170 {
171 document.styleEngine()->addPendingSheet(); 171 document.styleEngine()->addPendingSheet();
172 } 172 }
173 173
174 } 174 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698