| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Peter Kelly (pmk@post.com) | 2 * Copyright (C) 2000 Peter Kelly (pmk@post.com) |
| 3 * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved. | 3 * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 #include "core/xml/XSLStyleSheet.h" | 35 #include "core/xml/XSLStyleSheet.h" |
| 36 #include "core/xml/parser/XMLDocumentParser.h" // for parseAttributes() | 36 #include "core/xml/parser/XMLDocumentParser.h" // for parseAttributes() |
| 37 | 37 |
| 38 namespace blink { | 38 namespace blink { |
| 39 | 39 |
| 40 inline ProcessingInstruction::ProcessingInstruction(Document& document, const St
ring& target, const String& data) | 40 inline ProcessingInstruction::ProcessingInstruction(Document& document, const St
ring& target, const String& data) |
| 41 : CharacterData(document, data, CreateOther) | 41 : CharacterData(document, data, CreateOther) |
| 42 , m_target(target) | 42 , m_target(target) |
| 43 , m_loading(false) | 43 , m_loading(false) |
| 44 , m_alternate(false) | 44 , m_alternate(false) |
| 45 , m_createdByParser(false) | |
| 46 , m_isCSS(false) | 45 , m_isCSS(false) |
| 47 , m_isXSL(false) | 46 , m_isXSL(false) |
| 48 , m_listenerForXSLT(nullptr) | 47 , m_listenerForXSLT(nullptr) |
| 49 { | 48 { |
| 50 } | 49 } |
| 51 | 50 |
| 52 PassRefPtrWillBeRawPtr<ProcessingInstruction> ProcessingInstruction::create(Docu
ment& document, const String& target, const String& data) | 51 PassRefPtrWillBeRawPtr<ProcessingInstruction> ProcessingInstruction::create(Docu
ment& document, const String& target, const String& data) |
| 53 { | 52 { |
| 54 return adoptRefWillBeNoop(new ProcessingInstruction(document, target, data))
; | 53 return adoptRefWillBeNoop(new ProcessingInstruction(document, target, data))
; |
| 55 } | 54 } |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 260 Node::InsertionNotificationRequest ProcessingInstruction::insertedInto(Container
Node* insertionPoint) | 259 Node::InsertionNotificationRequest ProcessingInstruction::insertedInto(Container
Node* insertionPoint) |
| 261 { | 260 { |
| 262 CharacterData::insertedInto(insertionPoint); | 261 CharacterData::insertedInto(insertionPoint); |
| 263 if (!insertionPoint->inDocument()) | 262 if (!insertionPoint->inDocument()) |
| 264 return InsertionDone; | 263 return InsertionDone; |
| 265 | 264 |
| 266 String href; | 265 String href; |
| 267 String charset; | 266 String charset; |
| 268 bool isValid = checkStyleSheet(href, charset); | 267 bool isValid = checkStyleSheet(href, charset); |
| 269 if (!DocumentXSLT::processingInstructionInsertedIntoDocument(document(), thi
s)) | 268 if (!DocumentXSLT::processingInstructionInsertedIntoDocument(document(), thi
s)) |
| 270 document().styleEngine().addStyleSheetCandidateNode(this, m_createdByPar
ser); | 269 document().styleEngine().addStyleSheetCandidateNode(this); |
| 271 if (isValid) | 270 if (isValid) |
| 272 process(href, charset); | 271 process(href, charset); |
| 273 return InsertionDone; | 272 return InsertionDone; |
| 274 } | 273 } |
| 275 | 274 |
| 276 void ProcessingInstruction::removedFrom(ContainerNode* insertionPoint) | 275 void ProcessingInstruction::removedFrom(ContainerNode* insertionPoint) |
| 277 { | 276 { |
| 278 CharacterData::removedFrom(insertionPoint); | 277 CharacterData::removedFrom(insertionPoint); |
| 279 if (!insertionPoint->inDocument()) | 278 if (!insertionPoint->inDocument()) |
| 280 return; | 279 return; |
| (...skipping 26 matching lines...) Expand all Loading... |
| 307 | 306 |
| 308 DEFINE_TRACE(ProcessingInstruction) | 307 DEFINE_TRACE(ProcessingInstruction) |
| 309 { | 308 { |
| 310 visitor->trace(m_sheet); | 309 visitor->trace(m_sheet); |
| 311 visitor->trace(m_listenerForXSLT); | 310 visitor->trace(m_listenerForXSLT); |
| 312 CharacterData::trace(visitor); | 311 CharacterData::trace(visitor); |
| 313 ResourceOwner<StyleSheetResource>::trace(visitor); | 312 ResourceOwner<StyleSheetResource>::trace(visitor); |
| 314 } | 313 } |
| 315 | 314 |
| 316 } // namespace blink | 315 } // namespace blink |
| OLD | NEW |