Opened 8 years ago
Closed 7 years ago
#4784 closed Bug (fixed)
Incorrect cursor position after delete table cells
| Reported by: | Garry Yao | Owned by: | brooks |
|---|---|---|---|
| Priority: | Normal | Milestone: | CKEditor 3.3 |
| Component: | General | Version: | 3.0 |
| Keywords: | confirm Review+ | Cc: |
Description
Reproducing Procedures
- Open 'replacebyclass' sample page insert an default table.
- Click inside one of the table cell and open context menu on it.
- Click 'Cell->Delete Cells' to remove it.
- Actual Result: The cursor is not blinking at the same position agreed on all browsers, especially for some one the cursor is lost.
Attachments (3)
Change History (15)
comment:1 Changed 8 years ago by
| Milestone: | CKEditor 3.1 → CKEditor 3.2 |
|---|
comment:2 Changed 8 years ago by
| Milestone: | CKEditor 3.2 → CKEditor 3.3 |
|---|
comment:3 Changed 7 years ago by
| Keywords: | Confirmed added |
|---|---|
| Version: | SVN (CKEditor) → 3.0 |
comment:4 Changed 7 years ago by
| Owner: | set to brooks |
|---|
comment:5 Changed 7 years ago by
| Status: | new → assigned |
|---|
Changed 7 years ago by
| Attachment: | 4784.patch added |
|---|
comment:6 Changed 7 years ago by
| Keywords: | Review? added; Confirmed removed |
|---|
comment:7 Changed 7 years ago by
| Keywords: | Confirmed Review- added; Review? removed |
|---|
- Load the following content and selection into editor in Firefox:
<table> <tr><td>[cell1]</td><td>cell2</td></tr> <tr><td>[cell3]</td></tr> </table>
- Delete the selected cells using context menu.
- Expected Result: Cursor is blinking inside 'cell2'.
- Actual Result: Cursor is not blinking any more.
Changed 7 years ago by
| Attachment: | 4784_2.patch added |
|---|
comment:8 Changed 7 years ago by
| Keywords: | Review? added; Confirmed Review- removed |
|---|
update for 2 bugs:
- fix the algorithm for find the first focusable cell.
- if the last cell was deleted, delete the whole table.
comment:9 Changed 7 years ago by
| Keywords: | Review- added; Review? removed |
|---|
- fix the algorithm for find the first focusable cell.
With more robust logic right now, the patch increases the complexity of the cells deletion to O(n2) because of the 'indexOf' search, It's our common practice to use this way to filtering unwanted nodes, which could reduce to linear O(2n).
Changed 7 years ago by
| Attachment: | 4784_3.patch added |
|---|
comment:10 follow-up: 11 Changed 7 years ago by
| Keywords: | Review? added; Review- removed |
|---|
nice suggest!
comment:11 Changed 7 years ago by
| Keywords: | Review+ added; Review? removed |
|---|
Congs! The codes looks much neater.
comment:12 Changed 7 years ago by
| Keywords: | confirm added |
|---|---|
| Resolution: | → fixed |
| Status: | assigned → closed |
fixed with 5352

Similar with #4851.