Ticket #2018: 2018.patch

File 2018.patch, 2.8 KB (added by Martin Kou, 11 years ago)
  • _whatsnew.html

     
    120120                        when FCKeditor is installed to a different domain.</li>
    121121                <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2066">#2066</a>] Added a workaround for a Mac
    122122                        Safari 3.1 browser bug which caused the Fit Window button to give a blank screen.</li>
     123                <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2018">#2018</a>] Reversed the fix for
     124                        <a target="_blank" href="http://dev.fckeditor.net/ticket/183">#183</a> which broke FCKeditorAPI's cleanup
     125                        logic. A new configuration directive <strong>MsWebBrowserControlOnUnloadKludge</strong> has been added
     126                        for those who wish to force the #183 fix to be enabled.</li>
    123127        </ul>
    124128        <h3>
    125129                Version 2.6</h3>
  • editor/_source/classes/fckiecleanup.js

     
    4343
    4444function FCKIECleanup_Cleanup()
    4545{
    46         if ( !this._FCKCleanupObj || !window.FCKUnloadFlag )
     46        if ( !this._FCKCleanupObj || ( FCKConfig.MsWebBrowserControlOnUnloadKludge && !window.FCKUnloadFlag ) )
    4747                return ;
    4848
    4949        var aItems = this._FCKCleanupObj.Items ;
  • editor/_source/fckeditorapi.js

     
    164164
    165165function FCKeditorAPI_Cleanup()
    166166{
    167         if ( ! window.FCKUnloadFlag )
     167        alert( FCKConfig.MsWebBrowserControlOnUnloadKludge ) ;
     168        if ( window.FCKConfig && FCKConfig.MsWebBrowserControlOnUnloadKludge
     169                        && !window.FCKUnloadFlag )
    168170                return ;
    169171        delete FCKeditorAPI.Instances[ FCK.Name ] ;
    170172}
    171173function FCKeditorAPI_ConfirmCleanup()
    172174{
    173         window.FCKUnloadFlag = true ;
     175        if ( window.FCKConfig && FCKConfig.MsWebBrowserControlOnUnloadKludge )
     176                window.FCKUnloadFlag = true ;
    174177}
    175178FCKTools.AddEventListener( window, 'unload', FCKeditorAPI_Cleanup ) ;
    176179FCKTools.AddEventListener( window, 'beforeunload', FCKeditorAPI_ConfirmCleanup) ;
  • fckconfig.js

     
    314314
    315315FCKConfig.BackgroundBlockerColor = '#ffffff' ;
    316316FCKConfig.BackgroundBlockerOpacity = 0.50 ;
     317
     318// Enable the follow option to prevent FCKeditor from unloading itself
     319// when viewed under a WebBrowser control inside an application.
     320// NOT RECOMMENDED for normal websites as it causes other problems.
     321FCKConfig.MsWebBrowserControlOnUnloadKludge = false ;
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy