Opened 12 years ago
Closed 12 years ago
#9386 closed Bug (fixed)
[Webkit] Missing case for filler char in collapsed selection
Reported by: | Garry Yao | Owned by: | Garry Yao |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.6.5 |
Component: | Core : Selection | Version: | 3.6.5 |
Keywords: | Cc: |
Description (last modified by )
There's still some logic hole in filler char creating detection, which breaks the following TC:
Attachments (3)
Change History (10)
comment:1 Changed 12 years ago by
Owner: | set to Garry Yao |
---|---|
Status: | new → review |
Changed 12 years ago by
Attachment: | 9386.patch added |
---|
comment:2 Changed 12 years ago by
The above patch breaks some current TCs.
Considering that it's not easy to enumerate all possible (see code comments) DOM structure where an empty fix is required, so the proposal takes a new approach - rely on range::moveToElementEditStart/End to check whether the filler is needed, and I've opened t/9386@test that cited all known cases for now.
Changed 12 years ago by
Attachment: | 9386_2.patch added |
---|
comment:3 Changed 12 years ago by
Description: | modified (diff) |
---|
comment:4 Changed 12 years ago by
Status: | review → review_failed |
---|
I'm against the changes on CKEDITOR.dom.walker.invisible. They sound like a hack to achieve the fix here, at the price of making the function counterintuituve.
How should I expect an empty text node not to be invisible just because it may eventually be inside a visible element?... something like this: <p>Text<br>[Empty Text Node]</p>
Changed 12 years ago by
Attachment: | 9386_3.patch added |
---|
comment:5 Changed 12 years ago by
Status: | review_failed → review |
---|
comment:6 Changed 12 years ago by
Status: | review → review_passed |
---|
comment:7 Changed 12 years ago by
Resolution: | → fixed |
---|---|
Status: | review_passed → closed |
Fixed with [7624].
The patch expanded the filler creation check, in considering of hidden element.
Besides two commonly requested traversal utility are proposed in range.js.