summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/webkit/WebCore/dom/CDATASection.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/webkit/WebCore/dom/CDATASection.cpp')
-rw-r--r--src/3rdparty/webkit/WebCore/dom/CDATASection.cpp17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/3rdparty/webkit/WebCore/dom/CDATASection.cpp b/src/3rdparty/webkit/WebCore/dom/CDATASection.cpp
index 72faa7083..d73054e71 100644
--- a/src/3rdparty/webkit/WebCore/dom/CDATASection.cpp
+++ b/src/3rdparty/webkit/WebCore/dom/CDATASection.cpp
@@ -1,7 +1,7 @@
/*
* Copyright (C) 1999 Lars Knoll (knoll@kde.org)
* (C) 1999 Antti Koivisto (koivisto@kde.org)
- * Copyright (C) 2003, 2008 Apple Inc. All rights reserved.
+ * Copyright (C) 2003, 2008, 2009 Apple Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -26,13 +26,14 @@
namespace WebCore {
-CDATASection::CDATASection(Document* document, const String& text)
- : Text(document, text)
+inline CDATASection::CDATASection(Document* document, const String& data)
+ : Text(document, data)
{
}
-CDATASection::~CDATASection()
+PassRefPtr<CDATASection> CDATASection::create(Document* document, const String& data)
{
+ return adoptRef(new CDATASection(document, data));
}
String CDATASection::nodeName() const
@@ -47,19 +48,17 @@ Node::NodeType CDATASection::nodeType() const
PassRefPtr<Node> CDATASection::cloneNode(bool /*deep*/)
{
- return new CDATASection(document(), m_data);
+ return create(document(), data());
}
-// DOM Section 1.1.1
bool CDATASection::childTypeAllowed(NodeType)
{
return false;
}
-PassRefPtr<Text> CDATASection::createNew(PassRefPtr<StringImpl> string)
+PassRefPtr<Text> CDATASection::virtualCreate(const String& data)
{
- return new CDATASection(document(), string);
+ return create(document(), data);
}
-
} // namespace WebCore