Ticket #3573: 3573.patch

File 3573.patch, 1.4 KB (added by Garry Yao, 15 years ago)
  • _source/plugins/wysiwygarea/plugin.js

     
    5252                if ( this.mode == 'wysiwyg' )
    5353                {
    5454                        this.focus();
     55                        this.fire( 'saveSnapshot' );
    5556
    5657                        var element = evt.data,
    5758                                elementName = element.getName(),
     
    104105
    105106                        if ( selIsLocked )
    106107                                this.getSelection().lock();
     108
     109                        // Save snaps after the whole execution completed.
     110                        // This's a workaround for make DOM modification's happened after
     111                        // 'insertElement' to be included either, e.g. Form-based dialogs' 'commitContents'
     112                        // call.
     113                        CKEDITOR.tools.setTimeout( function(){
     114                                this.fire( 'saveSnapshot' );
     115                        }, 0, this );
    107116                }
    108117        }
    109118       
  • _source/plugins/dialog/plugin.js

     
    24412441                exec : function( editor )
    24422442                {
    24432443                        editor.openDialog( this.dialogName );
    2444                 }
     2444                },
     2445                // Dialog commands just open a dialog ui, thus require no undo logic,
     2446                // undo support should dedicate to specific dialog implementation.
     2447                canUndo: false
    24452448        };
    24462449
    24472450        (function()
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy