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

Unified Diff: third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp

Issue 2354773003: Make stylesheet owner node a reference instead of pointer. (Closed)
Patch Set: const Created 4 years, 3 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 | « third_party/WebKit/Source/core/dom/Document.cpp ('k') | third_party/WebKit/Source/core/dom/StyleElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp
diff --git a/third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp b/third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp
index a7c5b8c86cd1df4c1ba3c7397bbcaf924f0d7e45..43b2cf124fbe9d6469561ee6572cadf338276c56 100644
--- a/third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp
+++ b/third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp
@@ -185,7 +185,7 @@ bool ProcessingInstruction::sheetLoaded()
{
if (!isLoading()) {
if (!DocumentXSLT::sheetLoaded(document(), this))
- document().styleEngine().removePendingSheet(this, m_styleEngineContext);
+ document().styleEngine().removePendingSheet(*this, m_styleEngineContext);
return true;
}
return false;
@@ -203,7 +203,7 @@ void ProcessingInstruction::setCSSStyleSheet(const String& href, const KURL& bas
StyleSheetContents* newSheet = StyleSheetContents::create(href, parserContext);
- CSSStyleSheet* cssSheet = CSSStyleSheet::create(newSheet, this);
+ CSSStyleSheet* cssSheet = CSSStyleSheet::create(newSheet, *this);
cssSheet->setDisabled(m_alternate);
cssSheet->setTitle(m_title);
if (!m_alternate && !m_title.isEmpty())
@@ -257,7 +257,7 @@ Node::InsertionNotificationRequest ProcessingInstruction::insertedInto(Container
String charset;
bool isValid = checkStyleSheet(href, charset);
if (!DocumentXSLT::processingInstructionInsertedIntoDocument(document(), this))
- document().styleEngine().addStyleSheetCandidateNode(this);
+ document().styleEngine().addStyleSheetCandidateNode(*this);
if (isValid)
process(href, charset);
return InsertionDone;
@@ -271,7 +271,7 @@ void ProcessingInstruction::removedFrom(ContainerNode* insertionPoint)
// No need to remove XSLStyleSheet from StyleEngine.
if (!DocumentXSLT::processingInstructionRemovedFromDocument(document(), this))
- document().styleEngine().removeStyleSheetCandidateNode(this);
+ document().styleEngine().removeStyleSheetCandidateNode(*this);
StyleSheet* removedSheet = m_sheet;
if (m_sheet) {
@@ -291,7 +291,7 @@ void ProcessingInstruction::clearSheet()
{
DCHECK(m_sheet);
if (m_sheet->isLoading())
- document().styleEngine().removePendingSheet(this, m_styleEngineContext);
+ document().styleEngine().removePendingSheet(*this, m_styleEngineContext);
m_sheet.release()->clearOwnerNode();
}
« no previous file with comments | « third_party/WebKit/Source/core/dom/Document.cpp ('k') | third_party/WebKit/Source/core/dom/StyleElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698