| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
| 6 * Copyright (C) 2006 Samuel Weinig (sam@webkit.org) | 6 * Copyright (C) 2006 Samuel Weinig (sam@webkit.org) |
| 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 321 ASSERT(headElement); | 321 ASSERT(headElement); |
| 322 RefPtrWillBeRawPtr<HTMLTitleElement> titleElement = HTMLTitleElement::cr
eate(*d); | 322 RefPtrWillBeRawPtr<HTMLTitleElement> titleElement = HTMLTitleElement::cr
eate(*d); |
| 323 headElement->appendChild(titleElement); | 323 headElement->appendChild(titleElement); |
| 324 titleElement->appendChild(d->createTextNode(title), ASSERT_NO_EXCEPTION)
; | 324 titleElement->appendChild(d->createTextNode(title), ASSERT_NO_EXCEPTION)
; |
| 325 } | 325 } |
| 326 d->setSecurityOrigin(document().securityOrigin()->isolatedCopy()); | 326 d->setSecurityOrigin(document().securityOrigin()->isolatedCopy()); |
| 327 d->setContextFeatures(document().contextFeatures()); | 327 d->setContextFeatures(document().contextFeatures()); |
| 328 return d.release(); | 328 return d.release(); |
| 329 } | 329 } |
| 330 | 330 |
| 331 PassRefPtrWillBeRawPtr<Document> DOMImplementation::createDocument(const String&
type, LocalFrame* frame, const KURL& url, bool inViewSourceMode) | |
| 332 { | |
| 333 return createDocument(type, DocumentInit(url, frame), inViewSourceMode); | |
| 334 } | |
| 335 | |
| 336 PassRefPtrWillBeRawPtr<Document> DOMImplementation::createDocument(const String&
type, const DocumentInit& init, bool inViewSourceMode) | 331 PassRefPtrWillBeRawPtr<Document> DOMImplementation::createDocument(const String&
type, const DocumentInit& init, bool inViewSourceMode) |
| 337 { | 332 { |
| 338 if (inViewSourceMode) | 333 if (inViewSourceMode) |
| 339 return HTMLViewSourceDocument::create(init, type); | 334 return HTMLViewSourceDocument::create(init, type); |
| 340 | 335 |
| 341 // Plugins cannot take HTML and XHTML from us, and we don't even need to ini
tialize the plugin database for those. | 336 // Plugins cannot take HTML and XHTML from us, and we don't even need to ini
tialize the plugin database for those. |
| 342 if (type == "text/html") | 337 if (type == "text/html") |
| 343 return HTMLDocument::create(init); | 338 return HTMLDocument::create(init); |
| 344 if (type == "application/xhtml+xml") | 339 if (type == "application/xhtml+xml") |
| 345 return XMLDocument::createXHTML(init); | 340 return XMLDocument::createXHTML(init); |
| (...skipping 27 matching lines...) Expand all Loading... |
| 373 | 368 |
| 374 return HTMLDocument::create(init); | 369 return HTMLDocument::create(init); |
| 375 } | 370 } |
| 376 | 371 |
| 377 void DOMImplementation::trace(Visitor* visitor) | 372 void DOMImplementation::trace(Visitor* visitor) |
| 378 { | 373 { |
| 379 visitor->trace(m_document); | 374 visitor->trace(m_document); |
| 380 } | 375 } |
| 381 | 376 |
| 382 } | 377 } |
| OLD | NEW |