Opened 10 years ago
Closed 10 years ago
#12007 closed defect (fixed)
Editor EnterKeyHandling plugin will fail if using copy and paste in IE
Reported by: | Katie Vance | Owned by: | Jared Jurkiewicz |
---|---|---|---|
Priority: | high | Milestone: | 1.6 |
Component: | Editor | Version: | 1.5 |
Keywords: | IE, editor, EnterKeyHandling | Cc: | |
Blocked By: | Blocking: |
Description (last modified by )
In IE, the EnterKeyHandling plugin doesn't work correctly if you copy and paste a selection and then hit enter.
Steps to reproduce:
- Open tests\editor\EnterKeyHandling?.html
- In the blockNodeforEnter='DIV' editor window, select all the text and delete it.
- Type in anything.
- Copy all or part of what you typed and paste it after itself.
- Hit Enter.
The text will be split incorrectly. You can see other similar behavior if you paste a couple of times and hit enter from the middle of the text.
This will fail for all three, div, p, and br.
Attachments (2)
Change History (17)
comment:1 Changed 10 years ago by
Owner: | Jared Jurkiewicz deleted |
---|
comment:2 Changed 10 years ago by
comment:4 Changed 10 years ago by
ksv:
I've applied/checked in this. I've also fixed 12008, and worked around the error with IE (by avoiding the whole empty node mess). So, you can probably wokr on a fix for IE for that one now.
comment:5 Changed 10 years ago by
Attached the fix for the BR case as well. However, when I tested on webkit browsers I found that the copy and paste does not work as expected and breaks this plugin. Therefore, the new tests that I added are skipped for webkit browsers until #12024 is fixed.
comment:6 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:7 Changed 10 years ago by
Milestone: | tbd → 1.6 |
---|
comment:8 Changed 10 years ago by
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Starting with [23268] the EnterKeyHandling?.html test fails on safari, both mac and windows.
comment:9 Changed 10 years ago by
Owner: | set to Jared Jurkiewicz |
---|---|
Status: | reopened → new |
comment:10 Changed 10 years ago by
Owner: | changed from Jared Jurkiewicz to Katie Vance |
---|
Katy,
Please look into this, as these patches were yours.
comment:11 Changed 10 years ago by
Owner: | changed from Katie Vance to Jared Jurkiewicz |
---|
comment:12 Changed 10 years ago by
comment:13 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Reran UT on Windows and mac. Both pass with the tweaks. Closing bug again.
comment:14 Changed 10 years ago by
Description: | modified (diff) |
---|---|
Resolution: | fixed |
Status: | closed → reopened |
Thanks, that fixes mac/safari and mac/FF. Unfortunately, still failing in the copy/paste tests on mac/chrome. Windows looks OK.
comment:15 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
The reason it fails is because in IE, once you do a paste it will create a new separate text node for each paste. The algorithm isn't using the correct text node when it determines where to place the div, p, or br.
Attaching a patch with tests for the div and p case. The br case is a bit more complicated and on top of that, when I perform those steps within the br editor, IE crashes. I created ticket #12008 to track that as a separate issue issue.