WebCore:
authorjusting <justing@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 25 Sep 2007 08:57:03 +0000 (08:57 +0000)
committerjusting <justing@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 25 Sep 2007 08:57:03 +0000 (08:57 +0000)
commite0413d7f9443621ed87b33c21fe0feb1160ebff4
tree102254c6ee25870666a309eda8f614fc206d2a8d
parentf0848046bb5fa3297c05ee35a34e2b22350e65e8
WebCore:

        Reviewed by Darin.

        <rdar://problem/5483567>
        REGRESSION (Tiger only, workaround in AppKit on Leopard): Pasting words copied from TextEdit in Mail adds extra newline

        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplaceSelectionCommand::removeUnrenderedNodes): Added.
        (WebCore::ReplaceSelectionCommand::doApply): Call removeUnrenderedNodes
        to prevent unrendered spaces from interfering with paragraph merging.
        * editing/ReplaceSelectionCommand.h:

LayoutTests:

        Reviewed by Darin.

        <rdar://problem/5483567>
        REGRESSION (Tiger only, workaround in AppKit on Leopard): Pasting words copied from TextEdit in Mail adds extra newline

        Demonstrate fix:
        * editing/pasteboard/5483567.html: Added.
        * platform/mac/editing/pasteboard/5483567-expected.checksum: Added.
        * platform/mac/editing/pasteboard/5483567-expected.png: Added.
        * platform/mac/editing/pasteboard/5483567-expected.txt: Added.

        Unrendered nodes removed:
        * editing/pasteboard/nested-blocks-with-text-area-expected.txt:
        * editing/pasteboard/nested-blocks-with-text-field-expected.txt:
        * editing/pasteboard/paste-RTFD-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@25721 268f45cc-cd09-0410-ab3c-d52691b4dbfc
12 files changed:
LayoutTests/ChangeLog
LayoutTests/editing/pasteboard/5483567.html [new file with mode: 0644]
LayoutTests/editing/pasteboard/nested-blocks-with-text-area-expected.txt
LayoutTests/editing/pasteboard/nested-blocks-with-text-field-expected.txt
LayoutTests/editing/pasteboard/paste-RTFD-expected.txt
LayoutTests/platform/mac/editing/pasteboard/5483567-expected.checksum [new file with mode: 0644]
LayoutTests/platform/mac/editing/pasteboard/5483567-expected.png [new file with mode: 0644]
LayoutTests/platform/mac/editing/pasteboard/5483567-expected.txt [new file with mode: 0644]
WebCore/ChangeLog
WebCore/WebCore.xcodeproj/project.pbxproj
WebCore/editing/ReplaceSelectionCommand.cpp
WebCore/editing/ReplaceSelectionCommand.h