Opened 15 years ago

Closed 13 years ago

#3461 closed Bug (worksforme)

Backspace/delete doesn't work with many empty lines in Firefox

Reported by: Josh Nisly Owned by: Garry Yao
Priority: Normal Milestone:
Component: General Version: SVN (CKEditor) - OLD
Keywords: Cc:

Description

To duplicate, open the divreplace sample. Delete all the text, then hold down the enter key until the scrollbar is smaller than the down-arrow button on the scrollbar. Now try pressing backspace, delete, etc. Nothing will remove those lines. Now type another letter. Suddenly, all the lines can be deleted.

I can only reproduce this in FF on Windows (not linux), but I can reproduce it consistently there. V2 works correctly. This can be reproduced in the nightly sample.

Attachments (1)

3461.patch (743 bytes) - added by Garry Yao 15 years ago.

Download all attachments as: .zip

Change History (16)

comment:1 Changed 15 years ago by Josh Nisly

Summary: Backspace/delete don't work with many empty lines in FirefoxBackspace/delete doesn't work with many empty lines in Firefox

comment:2 Changed 15 years ago by Artur Formella

Keywords: Confirmed added

comment:3 Changed 15 years ago by Garry Yao

Owner: set to Garry Yao
Status: newassigned

A even more easy way to reproduce with nightly build:

Reproducing Procedures

  1. Open the replace by class example page;
  2. Click on 'New Page' button to clear all content;
  3. Hit 'enter' key, then hit 'backspace' key.
    • Expected Result: The new paragraph has been deleted.
    • Actual Result: The new paragraph is still there.

comment:4 Changed 15 years ago by Garry Yao

Keywords: CantFix added

After some investigation, this bug has been caused by the appearance of <br _moz_editor_bogus_node="TRUE" _moz_dirty=""/> inside the document, this happened when you clear the document content with the following ways:

  1. Switch to 'source', delete all codes and switch back;
  2. Click 'New Page' command.

Actually there's no way of preventing FF from generating this bogus node, and my testing shows that remove this node could never help to resolve the issue.
Since it belongs to some sort of browser bug and this case doesn't happen very often, we can hold this one for a while.

comment:5 Changed 15 years ago by Josh Nisly

It does seem like a browser weirdness, but V2 works correctly. Is there really no way to work around it?

comment:6 Changed 15 years ago by Garry Yao

Keywords: Review? added; CantFix removed

There's a workaround for this by guarding on the empty document data, putting our own padding br.
Highjinx, it's great if you can also reviewing this.

comment:7 Changed 15 years ago by Garry Yao

Milestone: CKEditor 3.0

comment:8 Changed 15 years ago by Josh Nisly

Did you mean to attach a patch?

comment:9 in reply to:  8 Changed 15 years ago by Garry Yao

Replying to highjinx_53:

Did you mean to attach a patch?

I mean please test the patch against your profile, and of course, attach a better fix at your will.

comment:10 Changed 15 years ago by Frederico Caldeira Knabben

Keywords: Review- added; Review? removed

Garry, you have asked review, but no patch is available here? I'm a bit confused. Can you clarify it?

Changed 15 years ago by Garry Yao

Attachment: 3461.patch added

comment:11 Changed 15 years ago by Garry Yao

Keywords: Review? added; Review- removed

I saw confusion here all because of missing of the patch file, my fault.

comment:12 Changed 15 years ago by Frederico Caldeira Knabben

I'll wait to review it only after #3505.

comment:13 Changed 15 years ago by Frederico Caldeira Knabben

Milestone: CKEditor 3.0CKEditor 3.x

I'm not able to reproduce this one, and Garry also thinks this one is hard to reproduce now, as e have introduced other features in the editor.

I'll still leave this opened for a while, so we can check whether it's needed or not.

comment:14 Changed 14 years ago by Frederico Caldeira Knabben

Milestone: CKEditor 3.x

Milestone CKEditor 3.x deleted

comment:15 Changed 13 years ago by Frederico Caldeira Knabben

Keywords: FirefoxConfirmed removed
Resolution: worksforme
Status: reviewclosed

Expired.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy