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

Issue 2250133004: No hang when inserting a list over uneditable element in contenteditable (Closed)

Created:
4 years, 4 months ago by joone
Modified:
4 years, 4 months ago
Reviewers:
yosin_UTC9
CC:
blink-reviews, chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

No hang when inserting a list over uneditable element in contenteditable While firstEditablePositionAfterPositionInRootAlgorithm() is running, we can get the next editable paragraph under the highest editable node by skipping non-editable paragraph. However, if an editable paragraph has a non-editable child, the next paragraph can be the same editable paragraph that is the parent of the non-editable child. In this case, we can't get the next editable paragraph in InsertListCommand::doApply's while loop. As a result, the while loop can't break, which makes the tab hang. Here is the example: <div contenteditable="true"> <p>line1<button contenteditable="false">hello</button></p> <p>line2</p> </div> This CL allows to get the next editable paragraph by considering the non-editable child element. BUG=571420 TEST=editing/selection/insert-list-over-uneditable-in-contenteditable.html Committed: https://crrev.com/f15d4cc339737df653274e39726ae0d14d409b18 Cr-Commit-Position: refs/heads/master@{#412925}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Remove extra blanks in the test case #

Unified diffs Side-by-side diffs Delta from patch set Stats (+19 lines, -1 line) Patch
A third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html View 1 1 chunk +10 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/editing/EditingUtilities.cpp View 1 chunk +9 lines, -1 line 0 comments Download

Messages

Total messages: 16 (10 generated)
joone
Hi yosin@ please review this CL.
4 years, 4 months ago (2016-08-18 07:12:29 UTC) #4
yosin_UTC9
lgtm w/ small nits Wonderful! https://codereview.chromium.org/2250133004/diff/1/third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html File third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html (right): https://codereview.chromium.org/2250133004/diff/1/third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html#newcode6 third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html:6: nit: we don't need ...
4 years, 4 months ago (2016-08-18 08:45:26 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2250133004/20001
4 years, 4 months ago (2016-08-18 18:21:50 UTC) #11
joone
Thanks for review! https://codereview.chromium.org/2250133004/diff/1/third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html File third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html (right): https://codereview.chromium.org/2250133004/diff/1/third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html#newcode6 third_party/WebKit/LayoutTests/editing/selection/insert-list-over-uneditable-in-contenteditable.html:6: On 2016/08/18 08:45:26, Yosi_UTC9 wrote: > ...
4 years, 4 months ago (2016-08-18 18:22:05 UTC) #12
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 4 months ago (2016-08-18 20:28:36 UTC) #14
commit-bot: I haz the power
4 years, 4 months ago (2016-08-18 20:29:55 UTC) #16
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/f15d4cc339737df653274e39726ae0d14d409b18
Cr-Commit-Position: refs/heads/master@{#412925}

Powered by Google App Engine
This is Rietveld 408576698