LayoutTests:
authorjusting <justing@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Nov 2006 03:52:33 +0000 (03:52 +0000)
committerjusting <justing@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Nov 2006 03:52:33 +0000 (03:52 +0000)
commit0a105ecb106e5ee38ce56709022390f6a7542652
treee49a4c44347f5403e4de3045ccb3f137317c7488
parent7405e07a515910bd8d3c3283c9ddf4a9adc1090b
LayoutTests:

        Reviewed by darin

        <rdar://problem/4062865>
        Copy/paste of a select element fails to include the options

        Updated to reflect fix:
        * editing/pasteboard/4641033-expected.checksum:
        * editing/pasteboard/4641033-expected.png:
        * editing/pasteboard/4641033-expected.txt:
        * editing/pasteboard/4641033.html:

        Added:
        * editing/inserting/before-after-input-element-expected.checksum: Added.
        * editing/inserting/before-after-input-element-expected.png: Added.
        * editing/inserting/before-after-input-element-expected.txt: Added.
        * editing/inserting/before-after-input-element.html: Added.
        * editing/pasteboard/input-field-1-expected.checksum: Added.
        * editing/pasteboard/input-field-1-expected.png: Added.
        * editing/pasteboard/input-field-1-expected.txt: Added.
        * editing/pasteboard/input-field-1.html: Added.
        * editing/pasteboard/select-element-1-expected.checksum: Added.
        * editing/pasteboard/select-element-1-expected.png: Added.
        * editing/pasteboard/select-element-1-expected.txt: Added.
        * editing/pasteboard/select-element-1.html: Added.
        * editing/selection/select-element-paragraph-boundary-expected.checksum: Added.
        * editing/selection/select-element-paragraph-boundary-expected.png: Added.
        * editing/selection/select-element-paragraph-boundary-expected.txt: Added.
        * editing/selection/select-element-paragraph-boundary.html: Added.

WebCore:

        Reviewed by darin

        <rdar://problem/4062865>
        Copy/paste of a select element fails to include the options

        * editing/SelectionController.cpp:
        (WebCore::SelectionController::modify): Added paragraphBoundary.
        * editing/htmlediting.cpp:
        (WebCore::canHaveChildrenForEditing): Added checks for input elements
        and textareas.  Insertion operations would fail when performed just
        before/after one of these elements b/c the content would be put inside
        the element.
        (WebCore::enclosingNodeWithTag): Fixed a problem when calling these in non
        editable content, and made the code to stop at an root faster (don't check
        isDescendantOf on every iteration).
        (WebCore::enclosingNodeOfType): Ditto.
        (WebCore::enclosingList): Ditto.
        (WebCore::enclosingListChild): Ditto.  Added a FIXME, this function seems
        inappropriately named.
        * editing/markup.cpp:
        (WebCore::startMarkup): Use the text node's value instead of its rendered
        content for text nodes inside select elements.  One might also turn off
        annotation when createMarkup enters a select element, but createMarkup
        is iterative, not recursive, so doing so would be complicated.
        (WebCore::createMarkup): Add markup for unrendered nodes if they are
        descendants of a select element.
        * editing/visible_units.cpp:
        (WebCore::startOfParagraph): Migrate to isBlock/enclosingBlock.  Fixes bug
        where various replaced elements can't be copied when they are the only
        thing selected.
        (WebCore::endOfParagraph): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17532 268f45cc-cd09-0410-ab3c-d52691b4dbfc
26 files changed:
LayoutTests/ChangeLog
LayoutTests/editing/inserting/before-after-input-element-expected.checksum [new file with mode: 0644]
LayoutTests/editing/inserting/before-after-input-element-expected.png [new file with mode: 0644]
LayoutTests/editing/inserting/before-after-input-element-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/before-after-input-element.html [new file with mode: 0644]
LayoutTests/editing/pasteboard/4641033-expected.checksum
LayoutTests/editing/pasteboard/4641033-expected.png
LayoutTests/editing/pasteboard/4641033-expected.txt
LayoutTests/editing/pasteboard/4641033.html
LayoutTests/editing/pasteboard/input-field-1-expected.checksum [new file with mode: 0644]
LayoutTests/editing/pasteboard/input-field-1-expected.png [new file with mode: 0644]
LayoutTests/editing/pasteboard/input-field-1-expected.txt [new file with mode: 0644]
LayoutTests/editing/pasteboard/input-field-1.html [new file with mode: 0644]
LayoutTests/editing/pasteboard/select-element-1-expected.checksum [new file with mode: 0644]
LayoutTests/editing/pasteboard/select-element-1-expected.png [new file with mode: 0644]
LayoutTests/editing/pasteboard/select-element-1-expected.txt [new file with mode: 0644]
LayoutTests/editing/pasteboard/select-element-1.html [new file with mode: 0644]
LayoutTests/editing/selection/select-element-paragraph-boundary-expected.checksum [new file with mode: 0644]
LayoutTests/editing/selection/select-element-paragraph-boundary-expected.png [new file with mode: 0644]
LayoutTests/editing/selection/select-element-paragraph-boundary-expected.txt [new file with mode: 0644]
LayoutTests/editing/selection/select-element-paragraph-boundary.html [new file with mode: 0644]
WebCore/ChangeLog
WebCore/editing/SelectionController.cpp
WebCore/editing/htmlediting.cpp
WebCore/editing/markup.cpp
WebCore/editing/visible_units.cpp