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

Unified Diff: Source/WebCore/dom/StyledElement.cpp

Issue 7169001: Merge 88601 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/782/
Patch Set: Created 9 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/WebCore/dom/StyledElement.h ('k') | Source/WebCore/html/HTMLBodyElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/dom/StyledElement.cpp
===================================================================
--- Source/WebCore/dom/StyledElement.cpp (revision 88860)
+++ Source/WebCore/dom/StyledElement.cpp (working copy)
@@ -439,7 +439,22 @@
style->addSubresourceStyleURLs(urls);
}
+void StyledElement::insertedIntoDocument()
+{
+ Element::insertedIntoDocument();
+ if (m_inlineStyleDecl)
+ m_inlineStyleDecl->setParent(document()->elementSheet());
+}
+
+void StyledElement::removedFromDocument()
+{
+ if (m_inlineStyleDecl)
+ m_inlineStyleDecl->setParent(0);
+
+ Element::removedFromDocument();
+}
+
void StyledElement::didMoveToNewOwnerDocument()
{
if (m_inlineStyleDecl)
« no previous file with comments | « Source/WebCore/dom/StyledElement.h ('k') | Source/WebCore/html/HTMLBodyElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698