Ticket #593: 593_Proposal2.patch

File 593_Proposal2.patch, 3.3 KB (added by OlaA, 11 years ago)

Modified proposal

  • editor/_source/internals/fck.js

    RCS file: /usr/local/cvsroot/ej/distbase/www/javascript/fckeditor/editor/_source/internals/fck.js,v
    retrieving revision 1.9
    diff -u -r1.9 fck.js
     
    1 /*
     1/*
    22 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
    33 * Copyright (C) 2003-2009 Frederico Caldeira Knabben
    44 *
     
    114114                this.EditingArea = new FCKEditingArea( document.getElementById( 'xEditingArea' ) ) ;
    115115                this.EditingArea.FFSpellChecker = FCKConfig.FirefoxSpellChecker ;
    116116
     117                FCK.EditMode = FCKConfig.StartupMode ;
     118
    117119                // Set the editor's startup contents.
    118120                this.SetData( this.GetLinkedFieldValue(), true ) ;
    119121
     
    329331
    330332        OnAfterSetHTML : function()
    331333        {
    332                 FCKDocumentProcessor.Process( FCK.EditorDocument ) ;
    333                 FCKUndo.SaveUndoStep() ;
     334                if ( FCK.EditMode == FCK_EDITMODE_WYSIWYG )
     335                {
     336                        FCKDocumentProcessor.Process( FCK.EditorDocument ) ;
     337                        FCKUndo.SaveUndoStep() ;
     338                }
     339
     340                // Check if it is not a startup call, otherwise complete the startup.
     341                if ( FCK.Status == FCK_STATUS_NOTLOADED )
     342                        FCK.SetStatus( FCK_STATUS_ACTIVE );
    334343
    335344                FCK.Events.FireEvent( 'OnSelectionChange' ) ;
    336345                FCK.Events.FireEvent( 'OnAfterSetHTML' ) ;
     
    491500
    492501                        this.EditingArea.Textarea.focus() ;
    493502
    494                         FCK.Events.FireEvent( 'OnAfterSetHTML' ) ;
     503                        //FCK.Events.FireEvent( 'OnAfterSetHTML' ) ;
     504                        FCK.OnAfterSetHTML() ;
    495505                }
    496506
    497507                if ( FCKBrowserInfo.IsGecko )
  • editor/_source/internals/fck_gecko.js

    RCS file: /usr/local/cvsroot/ej/distbase/www/javascript/fckeditor/editor/_source/internals/fck_gecko.js,v
    retrieving revision 1.8
    diff -u -r1.8 fck_gecko.js
     
    1 /*
     1/*
    22 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
    33 * Copyright (C) 2003-2009 Frederico Caldeira Knabben
    44 *
     
    488488
    489489FCK._ExecCheckEmptyBlock = function()
    490490{
     491        if (FCK.EditMode != FCK_EDITMODE_WYSIWYG)
     492                return;
     493   
    491494        FCK._FillEmptyBlock( FCK.EditorDocument.body.firstChild ) ;
    492495        var sel = FCKSelection.GetSelection() ;
    493496        if ( !sel || sel.rangeCount < 1 )
  • fckconfig.js

    RCS file: /usr/local/cvsroot/ej/distbase/www/javascript/fckeditor/fckconfig.js,v
    retrieving revision 1.10
    diff -u -r1.10 fckconfig.js
     
    1 /*
     1/*
    22 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
    33 * Copyright (C) 2003-2009 Frederico Caldeira Knabben
    44 *
     
    7979FCKConfig.EMailProtection = 'none' ; // none | encode | function
    8080FCKConfig.EMailProtectionFunction = 'mt(NAME,DOMAIN,SUBJECT,BODY)' ;
    8181
     82FCKConfig.StartupMode = FCK_EDITMODE_SOURCE;
    8283FCKConfig.StartupFocus  = false ;
    8384FCKConfig.ForcePasteAsPlainText = false ;
    8485FCKConfig.AutoDetectPasteFromWord = true ;      // IE only.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy