Ticket #9290 (confirmed Bug)

Opened 20 months ago

Last modified 19 months ago

Loading CKEditor in readOnly mode breaks the undo/redo toolbar buttons

Reported by: req Owned by:
Priority: Normal Milestone:
Component: UI : Toolbar Version: 3.6
Keywords: Cc: joel.peltonen@…

Description

Loading a CKEditor instance with the config setting

 readOnly = true

breaks the undo/redo user interface buttons. Ctrl-z and ctrl-y still work, but the undo and redo UI buttons never get activated, they remain grayed out.

Steps to reproduce: Load CKE with readOnly = true, set readonly to false and type. See This JSfiddle for an example. In the example, wait for the editor to be set editable, write something and the undo button never gets enabled but ctrl-z works. The undo buttons flash enabled every time the editor is set to readOnly false, but after focusing on the editor input they get grayed.

Tested in IE9 and Chrome13 on Win 7 64bit.

Attachments

readonly2.html (3.7 KB) - added by j.swiderski 20 months ago.

Change History

comment:1 Changed 20 months ago by j.swiderski

  • Status changed from new to confirmed
  • Keywords undo readOnly UI removed
  • Version changed from 3.6.4 to 3.6

Problem has been reproducible in all browsers from CKEditor 3.6.

NOTE: Initial readOnly breaks undo/redo. It gets fixed once you switch to source and back.

Changed 20 months ago by j.swiderski

comment:2 Changed 19 months ago by req

This bug seems to affect C-Z functionality as well so that CTRL-Z doesn't work without switching to source and then back in some cases. For when example when I have two tables directly below each other and I delete the one below, C-Z does not work. This is an issue especially if the source view is not available to the users; is there a workaround other than switching to source?

Currently I load the editor enabled and disable on instanceReady, which fixes the issue quite well.

comment:3 Changed 19 months ago by req

Further still, the readOnly also affects cut. If you add the cut icon to my jsfiddle - the cut icon never activates. Also, in my production site the cut gets enabled when the editor is in readOnly state!

In my case (IE9) the cut bug shows up like this: 1) start in readOnly 2) setData to something 3) set readOnly false 4) select a piece of text, like a word 5) set readOnly true 6) setData to something 7) select a piece of text, like a word --> Cut icon is still enabled and also functional.

Note: See TracTickets for help on using tickets.
© 2003 – 2012 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy