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

Unified Diff: Source/web/WebDocument.cpp

Issue 270573008: Oilpan: Prepare to support garbage-collected Node in WebNode hierarchy. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: add FIXME comments Created 6 years, 7 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/web/ChromeClientImpl.cpp ('k') | Source/web/WebDocumentType.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/WebDocument.cpp
diff --git a/Source/web/WebDocument.cpp b/Source/web/WebDocument.cpp
index c5eb8ddef4f752e0dab84d88110457680805c483..2936f0f3d8ac158f674268d248f5c65d5b121c7c 100644
--- a/Source/web/WebDocument.cpp
+++ b/Source/web/WebDocument.cpp
@@ -254,7 +254,12 @@ WebReferrerPolicy WebDocument::referrerPolicy() const
WebElement WebDocument::createElement(const WebString& tagName)
{
TrackExceptionState exceptionState;
+#if ENABLE(OILPAN)
+ // FIXME: Document::createElement should return a raw pointer.
+ WebElement element(unwrap<Document>()->createElement(tagName, exceptionState).get());
+#else
WebElement element(unwrap<Document>()->createElement(tagName, exceptionState));
+#endif
if (exceptionState.hadException())
return WebElement();
return element;
@@ -301,18 +306,18 @@ v8::Handle<v8::Value> WebDocument::registerEmbedderCustomElement(const WebString
return constructor.v8Value();
}
-WebDocument::WebDocument(const PassRefPtr<Document>& elem)
+WebDocument::WebDocument(const PassRefPtrWillBeRawPtr<Document>& elem)
: WebNode(elem)
{
}
-WebDocument& WebDocument::operator=(const PassRefPtr<Document>& elem)
+WebDocument& WebDocument::operator=(const PassRefPtrWillBeRawPtr<Document>& elem)
{
m_private = elem;
return *this;
}
-WebDocument::operator PassRefPtr<Document>() const
+WebDocument::operator PassRefPtrWillBeRawPtr<Document>() const
{
return toDocument(m_private.get());
}
« no previous file with comments | « Source/web/ChromeClientImpl.cpp ('k') | Source/web/WebDocumentType.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698