2011-04-29 Emil Eklund <eae@chromium.org>
authoreae@chromium.org <eae@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 30 Apr 2011 00:23:01 +0000 (00:23 +0000)
committereae@chromium.org <eae@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 30 Apr 2011 00:23:01 +0000 (00:23 +0000)
commitf86c082963c538a83e61b111a01c7dcc15546ca3
tree62e11f059ae5997de2766594a7b0933d73c13bb3
parent126cb233b22f2f76453fddef1d074609edcecedc
2011-04-29  Emil Eklund  <eae@chromium.org>

        Reviewed by Tony Chang.

        Setting outerHTML should merge text nodes
        https://bugs.webkit.org/show_bug.cgi?id=52686

        Add test for setting Element.outerHTML.

        * fast/dom/set-outer-html-expected.txt: Added.
        * fast/dom/set-outer-html.html: Added.
2011-04-29  Emil Eklund  <eae@chromium.org>

        Reviewed by Tony Chang.

        Setting outerHTML should merge text nodes
        https://bugs.webkit.org/show_bug.cgi?id=52686

        When setting outerHTML adjacent text nodes should be merged. This matches
        the behavior of outerText and the IE implementation of outerHTML.

        Test: fast/dom/set-outer-html.html

        * html/HTMLElement.cpp:
        (WebCore::mergeWithNextTextNode): Move function to before setOuterHTML.
        (WebCore::HTMLElement::setOuterHTML): Merge adjacent text nodes after replacing the element.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@85374 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fast/dom/set-outer-html-expected.txt [new file with mode: 0644]
LayoutTests/fast/dom/set-outer-html.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/html/HTMLElement.cpp