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

Unified Diff: Source/core/xml/XSLTProcessor.cpp

Issue 22909053: Store the Document's encoding on the Document (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Set document encoding in DecodedDataDocumentParser instead of DocumentWriter Created 7 years, 4 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/page/FrameView.cpp ('k') | Source/web/ContextMenuClientImpl.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/xml/XSLTProcessor.cpp
diff --git a/Source/core/xml/XSLTProcessor.cpp b/Source/core/xml/XSLTProcessor.cpp
index d1807cd1cfba9dae9e55cb6d1e9593240b21219f..2c4f54784eff24b94c58fad03708e0bbdb22a7fc 100644
--- a/Source/core/xml/XSLTProcessor.cpp
+++ b/Source/core/xml/XSLTProcessor.cpp
@@ -26,7 +26,6 @@
#include "core/dom/DOMImplementation.h"
#include "core/dom/DocumentFragment.h"
#include "core/editing/markup.h"
-#include "core/loader/TextResourceDecoder.h"
#include "core/page/ContentSecurityPolicy.h"
#include "core/page/DOMWindow.h"
#include "core/page/Frame.h"
@@ -88,10 +87,7 @@ PassRefPtr<Document> XSLTProcessor::createDocumentFromSource(const String& sourc
frame->domWindow()->setDocument(result);
}
- RefPtr<TextResourceDecoder> decoder = TextResourceDecoder::create(sourceMIMEType);
- decoder->setEncoding(sourceEncoding.isEmpty() ? UTF8Encoding() : WTF::TextEncoding(sourceEncoding), TextResourceDecoder::EncodingFromXMLHeader);
- result->setDecoder(decoder.release());
-
+ result->setEncoding(sourceEncoding.isEmpty() ? UTF8Encoding() : WTF::TextEncoding(sourceEncoding));
result->setContent(documentSource);
return result.release();
« no previous file with comments | « Source/core/page/FrameView.cpp ('k') | Source/web/ContextMenuClientImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698