Bug 90206
| Summary: | Pasting of first newline into text area does not appear to work | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Joshua Lock (joshuagl) <joshua.lock> |
| Component: | HTML Editing | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | ap, cdumez, darin, enrica, jason, marijnh, pflynn, ravi.kasibhatla, rniwa, tkent, tony, webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | 528+ (Nightly build) | ||
| Hardware: | All | ||
| OS: | All | ||
Joshua Lock (joshuagl)
The first newline pasted into a an empty textarea isn't rendered.
Reproduced on: Safari 5.1.7 (Win), Chrome 20.0.1132.43 (Linux) and Chromium r144706.
Reproduction steps: Paste exactly one newline in an empty textarea. The first paste results in nothing.
Expected result: cursor on second line with new line inserted.
Actual result: cursor on first line.
Additional details: A second (and any following) pasted newline results in a newline being inserted.
Firefox 13 IE 9 and Opera 12.00 each work as expected.
From http://crbug.com/121627
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Joshua Lock (joshuagl)
I'd like to work on this, if someone with edit bugs would assign to me I'd appreciate it.
Marijn Haverbeke
It seems that this behavior, beyond happening on the first paste, also happens on any first paste following a subsequent setting of the textarea's `.value`. Also, the bug only manifests itself when the the paste happens at the end of the input's text.
This is causing CodeMirror bug https://github.com/marijnh/CodeMirror/issues/1474
Jason Crawford
I can reproduce this on in Chrome 30.0.1599.69 and in Safari 6.0.5 (8536.30.1) on Mac OS X.
Would love to see this fixed, because it messes up copy and paste in web-based spreadsheets. Can I help?
EWS
Committed 257205@main (a4612d781cd3): <https://commits.webkit.org/257205@main>
Reviewed commits have been landed. Closing PR #6953 and removing active labels.
Radar WebKit Bug Importer
<rdar://problem/102835846>