Index: WebCore/html/HTMLElement.cpp |
=================================================================== |
--- WebCore/html/HTMLElement.cpp (revision 67731) |
+++ WebCore/html/HTMLElement.cpp (working copy) |
@@ -266,11 +266,6 @@ |
return createMarkup(this); |
} |
-static bool useLegacyTreeBuilder(Document*) |
-{ |
- return false; |
-} |
- |
// FIXME: This logic should move into Range::createContextualFragment |
PassRefPtr<DocumentFragment> HTMLElement::deprecatedCreateContextualFragment(const String& markup, FragmentScriptingPermission scriptingPermission) |
{ |
@@ -341,13 +336,6 @@ |
Document* document = contextElement->document(); |
RefPtr<DocumentFragment> fragment; |
- if (useLegacyTreeBuilder(document)) { |
- fragment = contextElement->deprecatedCreateContextualFragment(markup); |
- if (!fragment) |
- ec = NO_MODIFICATION_ALLOWED_ERR; |
- return fragment; |
- } |
- |
fragment = DocumentFragment::create(document); |
if (document->isHTMLDocument()) { |
fragment->parseHTML(markup, contextElement); |
@@ -364,14 +352,6 @@ |
void HTMLElement::setInnerHTML(const String& html, ExceptionCode& ec) |
{ |
- // FIXME: This code can be removed, it's handled by the HTMLDocumentParser correctly. |
- if (useLegacyTreeBuilder(document()) && (hasLocalName(scriptTag) || hasLocalName(styleTag))) { |
- // Script and CSS source shouldn't be parsed as HTML. |
- removeChildren(); |
- appendChild(document()->createTextNode(html), ec); |
- return; |
- } |
- |
RefPtr<DocumentFragment> fragment = createFragmentFromSource(html, this, ec); |
if (fragment) |
replaceChildrenWithFragment(this, fragment.release(), ec); |