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

Unified Diff: Source/core/html/parser/HTMLViewSourceParser.cpp

Issue 277633002: Convert DocumentParser code to Use more reference (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Make TextDocument use reference as well 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/core/html/parser/HTMLViewSourceParser.h ('k') | Source/core/html/parser/TextDocumentParser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/parser/HTMLViewSourceParser.cpp
diff --git a/Source/core/html/parser/HTMLViewSourceParser.cpp b/Source/core/html/parser/HTMLViewSourceParser.cpp
index 3ecd086ba5bbf1c757540d5f722dfe4614ec5123..4288d3e900a82bc701b20adad6e659d7749c6906 100644
--- a/Source/core/html/parser/HTMLViewSourceParser.cpp
+++ b/Source/core/html/parser/HTMLViewSourceParser.cpp
@@ -33,10 +33,9 @@
namespace WebCore {
-// FIXME: HTMLViewSourceDocument should be a reference.
-HTMLViewSourceParser::HTMLViewSourceParser(HTMLViewSourceDocument* document, const String& mimeType)
- : DecodedDataDocumentParser(*document)
- , m_tokenizer(HTMLTokenizer::create(HTMLParserOptions(document)))
+HTMLViewSourceParser::HTMLViewSourceParser(HTMLViewSourceDocument& document, const String& mimeType)
+ : DecodedDataDocumentParser(document)
+ , m_tokenizer(HTMLTokenizer::create(HTMLParserOptions(&document)))
{
if (mimeType != "text/html" && !DOMImplementation::isXMLMIMEType(mimeType))
m_tokenizer->setState(HTMLTokenizer::PLAINTEXTState);
« no previous file with comments | « Source/core/html/parser/HTMLViewSourceParser.h ('k') | Source/core/html/parser/TextDocumentParser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698