X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=_source%2Fplugins%2Fundo%2Fplugin.js;h=4909cadc967a4eecf452478e47cc66ed613bd3f0;hp=fcdd2a4e4803d853e79fc8963cb9f6542208cc81;hb=941b0a9ba4e673e292510d80a5a86806994b8ea6;hpb=7cd80714081a8ffdf4a1a8d2c72f120ed5ef3d6d diff --git a/_source/plugins/undo/plugin.js b/_source/plugins/undo/plugin.js index fcdd2a4..4909cad 100644 --- a/_source/plugins/undo/plugin.js +++ b/_source/plugins/undo/plugin.js @@ -1,5 +1,5 @@ /* -Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved. +Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ @@ -242,6 +242,9 @@ For licensing, see LICENSE.html or http://ckeditor.com/license if ( beforeTypeImage.contents != currentSnapshot ) { + // It's safe to now indicate typing state. + this.typing = true; + // This's a special save, with specified snapshot // and without auto 'fireChange'. if ( !this.save( false, beforeTypeImage, false ) ) @@ -263,9 +266,6 @@ For licensing, see LICENSE.html or http://ckeditor.com/license this.lastKeystroke = keystroke; - // Ignore modifier keys. (#4673) - if( isModifierKey ) - return; // Create undo snap after typed too much (over 25 times). if ( isEditingKey ) { @@ -274,7 +274,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license if ( this.modifiersCount > 25 ) { - this.save(); + this.save( false, null, false ); this.modifiersCount = 1; } } @@ -285,12 +285,11 @@ For licensing, see LICENSE.html or http://ckeditor.com/license if ( this.typesCount > 25 ) { - this.save(); + this.save( false, null, false ); this.typesCount = 1; } } - this.typing = true; }, reset : function() // Reset the undo stack.