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

Side by Side Diff: Source/core/xml/DocumentXSLT.cpp

Issue 1099613003: Oilpan: have xml/ objects on the heap by default. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: simplify XPathResult dtor Created 5 years, 8 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 unified diff | Download patch
« no previous file with comments | « Source/core/xml/DocumentXPathEvaluator.cpp ('k') | Source/core/xml/NativeXPathNSResolver.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/xml/DocumentXSLT.h" 6 #include "core/xml/DocumentXSLT.h"
7 7
8 #include "bindings/core/v8/DOMWrapperWorld.h" 8 #include "bindings/core/v8/DOMWrapperWorld.h"
9 #include "bindings/core/v8/ScriptState.h" 9 #include "bindings/core/v8/ScriptState.h"
10 #include "bindings/core/v8/V8AbstractEventListener.h" 10 #include "bindings/core/v8/V8AbstractEventListener.h"
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 95
96 DocumentXSLT::DocumentXSLT() 96 DocumentXSLT::DocumentXSLT()
97 : m_transformSourceDocument(nullptr) 97 : m_transformSourceDocument(nullptr)
98 { 98 {
99 } 99 }
100 100
101 void DocumentXSLT::applyXSLTransform(Document& document, ProcessingInstruction* pi) 101 void DocumentXSLT::applyXSLTransform(Document& document, ProcessingInstruction* pi)
102 { 102 {
103 ASSERT(!pi->isLoading()); 103 ASSERT(!pi->isLoading());
104 UseCounter::count(document, UseCounter::XSLProcessingInstruction); 104 UseCounter::count(document, UseCounter::XSLProcessingInstruction);
105 RefPtrWillBeRawPtr<XSLTProcessor> processor = XSLTProcessor::create(document ); 105 XSLTProcessor* processor = XSLTProcessor::create(document);
106 processor->setXSLStyleSheet(toXSLStyleSheet(pi->sheet())); 106 processor->setXSLStyleSheet(toXSLStyleSheet(pi->sheet()));
107 String resultMIMEType; 107 String resultMIMEType;
108 String newSource; 108 String newSource;
109 String resultEncoding; 109 String resultEncoding;
110 document.setParsingState(Document::Parsing); 110 document.setParsingState(Document::Parsing);
111 if (!processor->transformToString(&document, resultMIMEType, newSource, resu ltEncoding)) { 111 if (!processor->transformToString(&document, resultMIMEType, newSource, resu ltEncoding)) {
112 document.setParsingState(Document::FinishedParsing); 112 document.setParsingState(Document::FinishedParsing);
113 return; 113 return;
114 } 114 }
115 // FIXME: If the transform failed we should probably report an error (like M ozilla does). 115 // FIXME: If the transform failed we should probably report an error (like M ozilla does).
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 return *supplement; 196 return *supplement;
197 } 197 }
198 198
199 DEFINE_TRACE(DocumentXSLT) 199 DEFINE_TRACE(DocumentXSLT)
200 { 200 {
201 visitor->trace(m_transformSourceDocument); 201 visitor->trace(m_transformSourceDocument);
202 WillBeHeapSupplement<Document>::trace(visitor); 202 WillBeHeapSupplement<Document>::trace(visitor);
203 } 203 }
204 204
205 } // namespace blink 205 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/xml/DocumentXPathEvaluator.cpp ('k') | Source/core/xml/NativeXPathNSResolver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698