| 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 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. |
| 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 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. | 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. |
| 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. |
| (...skipping 780 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 791 { | 791 { |
| 792 return Comment::create(*this, data); | 792 return Comment::create(*this, data); |
| 793 } | 793 } |
| 794 | 794 |
| 795 PassRefPtr<CDATASection> Document::createCDATASection(const String& data, Except
ionState& es) | 795 PassRefPtr<CDATASection> Document::createCDATASection(const String& data, Except
ionState& es) |
| 796 { | 796 { |
| 797 if (isHTMLDocument()) { | 797 if (isHTMLDocument()) { |
| 798 es.throwDOMException(NotSupportedError); | 798 es.throwDOMException(NotSupportedError); |
| 799 return 0; | 799 return 0; |
| 800 } | 800 } |
| 801 if (data.find("]]>") != WTF::notFound) { | 801 if (data.find("]]>") != WTF::kNotFound) { |
| 802 es.throwDOMException(InvalidCharacterError, "String cannot contain ']]>'
since that is the end delimiter of a CData section."); | 802 es.throwDOMException(InvalidCharacterError, "String cannot contain ']]>'
since that is the end delimiter of a CData section."); |
| 803 return 0; | 803 return 0; |
| 804 } | 804 } |
| 805 return CDATASection::create(*this, data); | 805 return CDATASection::create(*this, data); |
| 806 } | 806 } |
| 807 | 807 |
| 808 PassRefPtr<ProcessingInstruction> Document::createProcessingInstruction(const St
ring& target, const String& data, ExceptionState& es) | 808 PassRefPtr<ProcessingInstruction> Document::createProcessingInstruction(const St
ring& target, const String& data, ExceptionState& es) |
| 809 { | 809 { |
| 810 if (!isValidName(target)) { | 810 if (!isValidName(target)) { |
| 811 es.throwDOMException(InvalidCharacterError); | 811 es.throwDOMException(InvalidCharacterError); |
| (...skipping 4140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4952 m_topLayerElements.append(element); | 4952 m_topLayerElements.append(element); |
| 4953 } | 4953 } |
| 4954 element->setIsInTopLayer(true); | 4954 element->setIsInTopLayer(true); |
| 4955 } | 4955 } |
| 4956 | 4956 |
| 4957 void Document::removeFromTopLayer(Element* element) | 4957 void Document::removeFromTopLayer(Element* element) |
| 4958 { | 4958 { |
| 4959 if (!element->isInTopLayer()) | 4959 if (!element->isInTopLayer()) |
| 4960 return; | 4960 return; |
| 4961 size_t position = m_topLayerElements.find(element); | 4961 size_t position = m_topLayerElements.find(element); |
| 4962 ASSERT(position != notFound); | 4962 ASSERT(position != kNotFound); |
| 4963 m_topLayerElements.remove(position); | 4963 m_topLayerElements.remove(position); |
| 4964 element->setIsInTopLayer(false); | 4964 element->setIsInTopLayer(false); |
| 4965 } | 4965 } |
| 4966 | 4966 |
| 4967 HTMLDialogElement* Document::activeModalDialog() const | 4967 HTMLDialogElement* Document::activeModalDialog() const |
| 4968 { | 4968 { |
| 4969 if (m_topLayerElements.isEmpty()) | 4969 if (m_topLayerElements.isEmpty()) |
| 4970 return 0; | 4970 return 0; |
| 4971 return toHTMLDialogElement(m_topLayerElements.last().get()); | 4971 return toHTMLDialogElement(m_topLayerElements.last().get()); |
| 4972 } | 4972 } |
| (...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5381 { | 5381 { |
| 5382 return DocumentLifecycleNotifier::create(this); | 5382 return DocumentLifecycleNotifier::create(this); |
| 5383 } | 5383 } |
| 5384 | 5384 |
| 5385 DocumentLifecycleNotifier* Document::lifecycleNotifier() | 5385 DocumentLifecycleNotifier* Document::lifecycleNotifier() |
| 5386 { | 5386 { |
| 5387 return static_cast<DocumentLifecycleNotifier*>(ScriptExecutionContext::lifec
ycleNotifier()); | 5387 return static_cast<DocumentLifecycleNotifier*>(ScriptExecutionContext::lifec
ycleNotifier()); |
| 5388 } | 5388 } |
| 5389 | 5389 |
| 5390 } // namespace WebCore | 5390 } // namespace WebCore |
| OLD | NEW |