Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(125)

Issue 18644008: Avoid adding placeholder when deleting last text in root (Closed)

Created:
7 years, 5 months ago by leviw_travelin_and_unemployed
Modified:
7 years, 5 months ago
Reviewers:
ojan, yosin_UTC9, eseidel
CC:
blink-reviews, dglazkov+blink, eae+blinkwatch, adamk+blink_chromium.org
Visibility:
Public.

Description

Avoid adding placeholder when deleting last text in root Editing code uses placeholders for all manner of different functions including holding open content editable blocks. When there's no content in the blocks except text, these placeholders aren't necessary and is confusing Android's IME path. Android's IME path should probably just be fixed, but in the meantime, this creates fewer placeholders, which is definitely an improvement. The previous version of this patch was rolled out due to crashes, see https://codereview.chromium.org/14969020. This patch adds a check in cleanupAfterDeletion to ensure we don't remove ancestors of our destination node, and yosin@ landed another fix in https://codereview.chromium.org/16053005/. BUG=222806, 236726 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=154347

Patch Set 1 #

Total comments: 2

Patch Set 2 : Fixing up test expectations #

Patch Set 3 : Add additional tests that need rebaselines #

Unified diffs Side-by-side diffs Delta from patch set Stats (+63 lines, -66 lines) Patch
M LayoutTests/TestExpectations View 1 2 1 chunk +15 lines, -0 lines 0 comments Download
M LayoutTests/editing/deleting/5847330-2-expected.txt View 1 chunk +0 lines, -1 line 0 comments Download
M LayoutTests/editing/deleting/delete-across-editable-content-boundaries-1-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/editing/deleting/delete-and-cleanup.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/editing/deleting/delete-and-cleanup-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/editing/deleting/delete-block-merge-contents-025-expected.txt View 1 chunk +0 lines, -2 lines 0 comments Download
M LayoutTests/editing/deleting/delete-select-all-002-expected.txt View 1 chunk +1 line, -3 lines 0 comments Download
M LayoutTests/editing/deleting/delete-start-block-expected.txt View 1 chunk +2 lines, -2 lines 0 comments Download
M LayoutTests/editing/deleting/paste-with-transparent-background-color-expected.txt View 1 chunk +0 lines, -1 line 0 comments Download
M LayoutTests/editing/execCommand/forward-delete-no-scroll-expected.txt View 1 chunk +0 lines, -1 line 0 comments Download
M LayoutTests/editing/execCommand/insertHTML-expected.txt View 1 chunk +1 line, -2 lines 0 comments Download
M LayoutTests/editing/pasteboard/select-element-1-expected.txt View 2 chunks +2 lines, -3 lines 0 comments Download
M LayoutTests/editing/pasteboard/smart-paste-in-text-control-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/editing/spelling/spellcheck-paste-continuous-disabled-expected.txt View 1 chunk +0 lines, -1 line 0 comments Download
M LayoutTests/fast/events/event-input-contentEditable-expected.txt View 2 chunks +2 lines, -2 lines 0 comments Download
M LayoutTests/fast/events/script-tests/event-input-contentEditable.js View 2 chunks +2 lines, -2 lines 0 comments Download
M LayoutTests/fast/parser/nested-fragment-parser-crash-expected.txt View 1 chunk +3 lines, -0 lines 0 comments Download
M LayoutTests/platform/win/editing/deleting/5272440-expected.txt View 1 chunk +0 lines, -1 line 0 comments Download
M LayoutTests/platform/win/editing/deleting/delete-3775172-fix-expected.txt View 2 chunks +2 lines, -5 lines 0 comments Download
M LayoutTests/platform/win/editing/deleting/delete-all-text-in-text-field-assertion-expected.txt View 1 chunk +0 lines, -1 line 0 comments Download
M LayoutTests/platform/win/editing/deleting/delete-block-contents-001-expected.txt View 2 chunks +1 line, -3 lines 0 comments Download
M LayoutTests/platform/win/editing/deleting/delete-block-contents-002-expected.txt View 2 chunks +1 line, -3 lines 0 comments Download
M LayoutTests/platform/win/editing/deleting/delete-block-contents-003-expected.txt View 2 chunks +1 line, -3 lines 0 comments Download
M LayoutTests/platform/win/editing/deleting/delete-image-004-expected.txt View 2 chunks +2 lines, -3 lines 0 comments Download
M LayoutTests/platform/win/editing/inserting/insert-3775316-fix-expected.txt View 1 chunk +1 line, -2 lines 0 comments Download
M LayoutTests/platform/win/editing/inserting/insert-after-delete-001-expected.txt View 1 chunk +1 line, -2 lines 0 comments Download
M LayoutTests/platform/win/editing/pasteboard/4076267-3-expected.txt View 1 chunk +1 line, -2 lines 0 comments Download
M LayoutTests/platform/win/fast/forms/input-placeholder-visibility-3-expected.txt View 1 chunk +1 line, -2 lines 0 comments Download
M LayoutTests/platform/win/fast/forms/textarea-placeholder-visibility-1-expected.txt View 1 chunk +1 line, -2 lines 0 comments Download
M Source/core/editing/CompositeEditCommand.cpp View 1 chunk +12 lines, -6 lines 0 comments Download
M Source/core/editing/DeleteSelectionCommand.cpp View 1 1 chunk +6 lines, -3 lines 0 comments Download
M Source/core/html/HTMLInputElement.cpp View 1 1 chunk +1 line, -4 lines 0 comments Download

Messages

Total messages: 13 (0 generated)
leviw_travelin_and_unemployed
7 years, 5 months ago (2013-07-11 23:17:30 UTC) #1
ojan
lgtm
7 years, 5 months ago (2013-07-11 23:37:23 UTC) #2
ojan
https://codereview.chromium.org/18644008/diff/1/LayoutTests/TestExpectations File LayoutTests/TestExpectations (right): https://codereview.chromium.org/18644008/diff/1/LayoutTests/TestExpectations#newcode1378 LayoutTests/TestExpectations:1378: crbug.com/222806 editing/deleting/delete-block-contents-001.html [ Failure Pass ImageOnlyFailure ] NeedsRebaseline?
7 years, 5 months ago (2013-07-11 23:37:46 UTC) #3
yosin_UTC9
https://chromiumcodereview.appspot.com/18644008/diff/1/Source/core/editing/CompositeEditCommand.cpp File Source/core/editing/CompositeEditCommand.cpp (right): https://chromiumcodereview.appspot.com/18644008/diff/1/Source/core/editing/CompositeEditCommand.cpp#newcode1054 Source/core/editing/CompositeEditCommand.cpp:1054: // Bail if we'd remove an ancestor of our ...
7 years, 5 months ago (2013-07-12 01:55:28 UTC) #4
leviw_travelin_and_unemployed
On 2013/07/12 01:55:28, Yoshifumi Inoue wrote: > https://chromiumcodereview.appspot.com/18644008/diff/1/Source/core/editing/CompositeEditCommand.cpp > File Source/core/editing/CompositeEditCommand.cpp (right): > > https://chromiumcodereview.appspot.com/18644008/diff/1/Source/core/editing/CompositeEditCommand.cpp#newcode1054 ...
7 years, 5 months ago (2013-07-12 21:12:40 UTC) #5
leviw_travelin_and_unemployed
On 2013/07/12 21:12:40, Levi wrote: > On 2013/07/12 01:55:28, Yoshifumi Inoue wrote: > > > ...
7 years, 5 months ago (2013-07-12 21:13:00 UTC) #6
leviw_travelin_and_unemployed
Yosin, do you still object to this? Can you explain how you expect this to ...
7 years, 5 months ago (2013-07-15 19:12:51 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/leviw@chromium.org/18644008/1
7 years, 5 months ago (2013-07-16 17:17:42 UTC) #8
commit-bot: I haz the power
Can't process patch for file LayoutTests/platform/win/editing/deleting/delete-block-contents-001-expected.png. Binary file support is temporarilly disabled due to a ...
7 years, 5 months ago (2013-07-16 17:17:46 UTC) #9
leviw_travelin_and_unemployed
I'm moving forward for the time being. yosin@, let me know if you want to ...
7 years, 5 months ago (2013-07-16 17:17:55 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/leviw@chromium.org/18644008/20001
7 years, 5 months ago (2013-07-16 23:00:05 UTC) #11
commit-bot: I haz the power
Change committed as 154347
7 years, 5 months ago (2013-07-17 01:42:48 UTC) #12
yosin_UTC9
7 years, 5 months ago (2013-07-17 02:14:49 UTC) #13
Message was sent while issue was closed.
On 2013/07/15 19:12:51, Levi wrote:
> Yosin, do you still object to this? Can you explain how you expect this to
> change results?

Sorry for late response. I was vacation on July 16.
It is OK to commit as is. I'd just wanted to know which tests were affected by
changes in CompositeEditCommand.cpp.
Anyway, this isn't big matter people other than me. ;-)

Powered by Google App Engine
This is Rietveld 408576698