TinyMCE:API/tinymce.Editor/onRedo

From Moxiecode Documentation Wiki

Jump to: navigation, search

Contents

Event: onRedo

Summary

This event gets executed when the users redoes some action in the editor.

Syntax

event_callback(<tinymce.Editor> ed, <Object> l, <tinymce.UndoManager> um)

Parameters

ed
Sender object/Editor instance that is serializing an element.
l
Undo level, that the editor contents was redoed to.
um
Undo manager for the redo action.

Examples

// Adds an observer to the onRedo event using tinyMCE.init
tinyMCE.init({
   ...
   setup : function(ed) {
      ed.onRedo.add(function(ed, l) {
          console.debug('Redo was performed: ' + l.content);
      });
   }
});

// Adds an observer to the onRedo event using the render method
var ed = new tinymce.Editor('someid', {
   .. Some settings
});

ed.onRedo.add(function(ed, l) {
   console.debug('Redo was performed: ' + l.content);
});

ed.render();
Personal tools