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

Issue 2258663003: [InputEvent] Support |deleteByCut|&|insertFromPaste| with |dataTransfer| field (Closed)

Created:
4 years, 4 months ago by chongz
Modified:
4 years, 3 months ago
Reviewers:
yosin_UTC9, ojan
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

[InputEvent] Support |deleteByCut|&|insertFromPaste| with |dataTransfer| field * Event order: (see July F2F[1] and GitHub discussion[2]) 1. Clipboard API cut 2. (Clipboard update) 3. 'beforeinput' InputType=|deleteByCut| 4. (DOM update) 5. 'input' InputType=|deleteByCut| * Canceling 'beforeinput' will only prevent DOM update. * |dataTransfer| field: (see Editing spec discussion[3]) 1. NULL for |deleteByCut| (JS could always get from selection) 2. Readonly |dataTransfer| for |insertFromPaste| [1] Editing TF July F2F: https://docs.google.com/document/d/1XxIEF0So-kMF5mcJ03Yj0zsYMFRHEgXw1fV1K5FOwuQ/edit#heading=h.l9vlzb1oc68r [2] GitHub discussion for event order: https://github.com/w3c/editing/issues/144#issuecomment-240892363 [3] Editing spec discussion: https://github.com/w3c/editing/issues/144#issuecomment-240259209 Intent to Implement: https://groups.google.com/a/chromium.org/forum/#!searchin/blink-dev/InputEvent/blink-dev/RrnitB0OElc/rirueVekCwAJ BUG=639139 Committed: https://crrev.com/952c4101425ed85bf53ded777e5a882895646980 Cr-Commit-Position: refs/heads/master@{#414659}

Patch Set 1 : Support cut/paste with |dataTransfer| field and correct event order #

Total comments: 2

Patch Set 2 : yosin's review - Add tests for 'beforeinput' in destroyed iframe #

Total comments: 14

Patch Set 3 : yosin's review2, fix nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+251 lines, -33 lines) Patch
A third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html View 1 2 1 chunk +71 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/events/inputevents/inputevent-cut-paste.html View 1 2 1 chunk +93 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/fast/events/inputevents/inputevent-execcommand.html View 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt View 1 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/core/editing/EditingUtilities.h View 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/core/editing/EditingUtilities.cpp View 1 chunk +10 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/editing/Editor.h View 1 1 chunk +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/editing/Editor.cpp View 1 2 5 chunks +30 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/core/editing/commands/CompositeEditCommand.cpp View 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/editing/commands/EditorCommand.cpp View 1 2 5 chunks +8 lines, -13 lines 0 comments Download
M third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp View 1 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/events/InputEvent.h View 5 chunks +6 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/events/InputEvent.cpp View 5 chunks +21 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/events/InputEvent.idl View 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/core/events/InputEventInit.idl View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 56 (42 generated)
chongz
yosin@ PTAL at this 'beforeinput' CL for 'cut' and 'paste', thanks! (Will take a look ...
4 years, 4 months ago (2016-08-23 04:04:30 UTC) #20
yosin_UTC9
https://codereview.chromium.org/2258663003/diff/40001/third_party/WebKit/LayoutTests/fast/events/inputevents/inputevent-cut-paste.html File third_party/WebKit/LayoutTests/fast/events/inputevents/inputevent-cut-paste.html (right): https://codereview.chromium.org/2258663003/diff/40001/third_party/WebKit/LayoutTests/fast/events/inputevents/inputevent-cut-paste.html#newcode1 third_party/WebKit/LayoutTests/fast/events/inputevents/inputevent-cut-paste.html:1: <!DOCTYPE html> Could you add a test case which ...
4 years, 4 months ago (2016-08-23 04:23:54 UTC) #21
chongz
yosin@ I've added iframe tests and updated crash check, PTAL, thanks! https://codereview.chromium.org/2258663003/diff/120001/third_party/WebKit/Source/core/editing/Editor.cpp File third_party/WebKit/Source/core/editing/Editor.cpp (right): ...
4 years, 4 months ago (2016-08-24 01:43:27 UTC) #35
yosin_UTC9
https://codereview.chromium.org/2258663003/diff/120001/third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html File third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html (right): https://codereview.chromium.org/2258663003/diff/120001/third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html#newcode19 third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html:19: childDocument.open(); nit: You could write: childDocument.body.innerHTML = '<p id="editable" ...
4 years, 4 months ago (2016-08-24 02:11:44 UTC) #36
chongz
yosin@, I've updated as per your comments, PTAL again, thanks! https://codereview.chromium.org/2258663003/diff/120001/third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html File third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html (right): https://codereview.chromium.org/2258663003/diff/120001/third_party/WebKit/LayoutTests/fast/events/inputevents/beforeinput-remove-iframe-crash.html#newcode19 ...
4 years, 4 months ago (2016-08-24 02:42:01 UTC) #39
yosin_UTC9
lgtm
4 years, 4 months ago (2016-08-24 03:24:55 UTC) #40
chongz
ojan@ PTAL at this 'beforeinput' CL for cut and paste, thanks!
4 years, 4 months ago (2016-08-24 03:42:58 UTC) #42
chongz
On 2016/08/24 03:42:58, chongz wrote: > ojan@ PTAL at this 'beforeinput' CL for cut and ...
4 years, 3 months ago (2016-08-25 23:34:28 UTC) #45
ojan
lgtm
4 years, 3 months ago (2016-08-26 00:06:44 UTC) #47
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/2258663003/140001
4 years, 3 months ago (2016-08-26 00:07:59 UTC) #48
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_x64_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/269249)
4 years, 3 months ago (2016-08-26 02:10:02 UTC) #50
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/2258663003/140001
4 years, 3 months ago (2016-08-26 05:54:08 UTC) #52
commit-bot: I haz the power
Committed patchset #3 (id:140001)
4 years, 3 months ago (2016-08-26 06:33:47 UTC) #54
commit-bot: I haz the power
4 years, 3 months ago (2016-08-26 06:35:26 UTC) #56
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/952c4101425ed85bf53ded777e5a882895646980
Cr-Commit-Position: refs/heads/master@{#414659}

Powered by Google App Engine
This is Rietveld 408576698