Reviewed by Chris
authorkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 25 Oct 2004 21:52:20 +0000 (21:52 +0000)
committerkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 25 Oct 2004 21:52:20 +0000 (21:52 +0000)
commit856fd46156d5caf3e5e1a830cbd68318ada9c4a3
tree35cc21492ac0d8e6e6a59ca9f9bd63f139cd180d
parent0a00700dde86b91df9c43122b8ef74577ec2f11d
    Reviewed by Chris

        Fix for this bug:

        <rdar://problem/3820349> REGRESSION (Mail): select all, delete does not always delete everything

        * khtml/editing/htmlediting.cpp:
        (khtml::DeleteSelectionCommand::startPositionForDelete): New helper that determines when to
        expand the selection outwards when the selection is on the visible boundary of a root
        editable element. This fixes the bug. Note that this function also contains a little code
        I factored out of doApply: it also takes care of adjusting the selection in the smart delete case.
        (khtml::DeleteSelectionCommand::endPositionForDelete): Ditto.
        (khtml::DeleteSelectionCommand::doApply): Call new helpers. Refactored out the code as described.
        * khtml/editing/htmlediting.h: Declare new helpers.
        * layout-tests/editing/deleting/delete-select-all-001-expected.txt: Added.
        * layout-tests/editing/deleting/delete-select-all-001.html: Added.
        * layout-tests/editing/deleting/delete-select-all-002-expected.txt: Added.
        * layout-tests/editing/deleting/delete-select-all-002.html: Added.
        * layout-tests/editing/deleting/delete-select-all-003-expected.txt: Added.
        * layout-tests/editing/deleting/delete-select-all-003.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@7890 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/editing/deleting/delete-select-all-001-expected.txt [new file with mode: 0644]
LayoutTests/editing/deleting/delete-select-all-001.html [new file with mode: 0644]
LayoutTests/editing/deleting/delete-select-all-002-expected.txt [new file with mode: 0644]
LayoutTests/editing/deleting/delete-select-all-002.html [new file with mode: 0644]
LayoutTests/editing/deleting/delete-select-all-003-expected.txt [new file with mode: 0644]
LayoutTests/editing/deleting/delete-select-all-003.html [new file with mode: 0644]
WebCore/ChangeLog-2005-08-23
WebCore/khtml/editing/htmlediting.cpp
WebCore/khtml/editing/htmlediting.h