Opened 14 years ago

Closed 14 years ago

#5191 closed Bug (fixed)

Ajax sample: undo behaves improperly

Reported by: Frederico Caldeira Knabben Owned by: Alfonso Martínez de Lizarrondo
Priority: Normal Milestone: CKEditor 3.2
Component: Core : Undo & Redo Version: SVN (CKEditor) - OLD
Keywords: Confirmed Review- Cc:


  1. Load the Ajax sample.
  2. Type some text.
  3. Undo until the last possible undo step.
  4. Redo until the last redo step.

In step 3, the last undo should be from a few text to blank contents.

In step 4, the last redo should restore the entire typed text.

Currently, the user looses the text when performing the above steps.

Attachments (1)

5191.patch (1.4 KB) - added by Alfonso Martínez de Lizarrondo 14 years ago.
Proposed patch

Download all attachments as: .zip

Change History (4)

Changed 14 years ago by Alfonso Martínez de Lizarrondo

Attachment: 5191.patch added

Proposed patch

comment:1 Changed 14 years ago by Alfonso Martínez de Lizarrondo

Keywords: Review? added
Owner: set to Alfonso Martínez de Lizarrondo
Status: newassigned

The problem is similar to #4622. There's a first snapshot done automatically with the initial code that happens to be "<br>", which is turned into "<p><br></p>", but that patch doesn't fix this situation.

I've adjusted the save function so that in case that it's doing it for a redo call, it checks also the next snapshot to verify if that matches the current content, and so skip the save.

comment:2 Changed 14 years ago by Frederico Caldeira Knabben

Keywords: Review- added; Review? removed

There are still issues:

  • In the reported TC, there is an additional empty undo.
  • It still breaks the contents in the following TC:
  1. Load the ajax sample.
  1. Type some text.
  1. Remove the editor and recreate it.
  1. Type more text after the current text.
  1. Undo everything last step. The contents is empty, which is wrong... we should have the initial contents.
  1. Redo everything. Nothings happens... the redo looks blocked.

comment:3 Changed 14 years ago by Frederico Caldeira Knabben

Resolution: fixed
Status: assignedclosed

Fixed with [5163].

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