Ticket #3791: 3791_2.patch

File 3791_2.patch, 8.0 KB (added by Garry Yao, 15 years ago)
  • _source/plugins/scayt/dialogs/options.js

     
    194194                        return false;
    195195                }
    196196                //apply handler
    197                 dic[ this.getId() ].apply( null, [ this, dic_name, dic_buttons ] );
     197                window.dic[ this.getId() ].apply( null, [ this, dic_name, dic_buttons ] );
    198198
    199199                return true;
    200200        }
     
    303303                                var suc_massage = captions["succ_dic_create"];
    304304                                //console.info("--plugin ");
    305305
    306                                 scayt.createUserDictionary(dic_name,
     306                                window.scayt.createUserDictionary(dic_name,
    307307                                        function(arg)
    308308                                                {
    309309                                                        //console.info( "dic_create callback called with args" , arg );
     
    321321
    322322                        };
    323323
    324                 dic.dic_rename = function( el, dic_name , dic_buttons )
     324                dic.dic_rename = function( el, dic_name )
    325325                        {
    326326                                //
    327327                                // try to rename dictionary
     
    329329                                //console.info ( captions["err_dic_rename"] )
    330330                                var err_massage = captions["err_dic_rename"] || "";
    331331                                var suc_massage = captions["succ_dic_rename"] || "";
    332                                 scayt.renameUserDictionary(dic_name,
     332                                window.scayt.renameUserDictionary(dic_name,
    333333                                        function(arg)
    334334                                                {
    335335                                                        //console.info( "dic_rename callback called with args" , arg );
     
    354354
    355355                                // try to delete dictionary
    356356                                // @TODO: delete dict
    357                                 scayt.deleteUserDictionary(
     357                                window.scayt.deleteUserDictionary(
    358358                                        function(arg)
    359359                                                {
    360360                                                        //console.info( "dic_delete callback " , dic_name ,arg );
     
    379379                                var err_massage = captions["err_dic_restore"];
    380380                                var suc_massage = captions["succ_dic_restore"];
    381381
    382                                 scayt.restoreUserDictionary(dic_name,
     382                                window.scayt.restoreUserDictionary(dic_name,
    383383                                        function(arg)
    384384                                                {
    385385                                                        //console.info( "dic_restore callback called with args" , arg );
     
    435435
    436436                // * user dictionary
    437437                if ( userDicActive ){
    438                         scayt.getNameUserDictionary(
     438                        window.scayt.getNameUserDictionary(
    439439                        function( o )
    440440                        {
    441441                                var dic_name = o.dname;
  • _source/plugins/scayt/plugin.js

     
    1111(function()
    1212{
    1313        var commandName         = 'scaytcheck',
    14                 sc_on_cssclass  = 'scayt_enabled',
    15                 sc_off_cssclass = 'scayt_disabled',
    1614                openPage                = '';
    1715
    1816        var onEngineLoad = function()
     
    4038                                }
    4139                        }
    4240
    43                         var scayt_control = new scayt( oParams );
     41                        var scayt_control = new window.scayt( oParams );
    4442
    4543                        // Copy config.
    4644                        var     lastInstance = plugin.instances[ editor.name ];
     
    120118
    121119                editor.on( 'scaytDialog', function( ev )        // Communication with dialog.
    122120                        {
    123                                 ev.data.djConfig = djConfig;
     121                                ev.data.djConfig = window.djConfig;
    124122                                ev.data.scayt_control = plugin.getScayt( editor );
    125123                                ev.data.tab = openPage;
    126                                 ev.data.scayt = scayt;
     124                                ev.data.scayt = window.scayt;
    127125                        });
    128126
    129127                var dataProcessor = editor.dataProcessor,
     
    157155                instances : {},
    158156                getScayt : function( editor )
    159157                {
    160                         var instance = this.instances[ editor.name ];
    161                         return instance;
     158                        return this.instances[ editor.name ];
    162159                },
    163160                isScaytReady : function( editor )
    164161                {
    165162                        return this.engineLoaded === true &&
    166                                 'undefined' !== typeof scayt && this.getScayt( editor );
     163                                'undefined' !== typeof window.scayt && this.getScayt( editor );
    167164                },
    168165                isScaytEnabled : function( editor )
    169166                {
     
    379376                        // If the "contextmenu" plugin is loaded, register the listeners.
    380377                        if ( editor.contextMenu && editor.addMenuItems )
    381378                        {
    382                                 editor.contextMenu.addListener( function( element, selection )
     379                                editor.contextMenu.addListener( function( element )
    383380                                        {
    384381                                                if ( !( plugin.isScaytEnabled( editor ) && element ) )
    385382                                                        return null;
     
    392389
    393390                                                var sLang = scayt_control.getLang(),
    394391                                                        _r = {},
    395                                                         items_suggestion = scayt.getSuggestion( word, sLang );
     392                                                        items_suggestion = window.scayt.getSuggestion( word, sLang );
    396393                                                if (!items_suggestion || !items_suggestion.length )
    397394                                                        return null;
    398395                                                // Remove unused commands and menuitems
     
    417414                                                        var exec = ( function( el, s )
    418415                                                                {
    419416                                                                        return {
    420                                                                                 exec: function( editor )
     417                                                                                exec: function()
    421418                                                                                {
    422419                                                                                        scayt_control.replace(el, s);
    423420                                                                                }
     
    471468                                                {
    472469                                                        exec: function()
    473470                                                        {
    474                                                                 scayt.addWordToUserDictionary( element.$ );
     471                                                                window.scayt.addWordToUserDictionary( element.$ );
    475472                                                        }
    476473                                                };
    477474
  • _source/plugins/wsc/dialogs/wsc.js

     
    5555                                initAndSpell( dialog );
    5656                        }
    5757                        else if ( i++ == 180 )                                                          // Timeout: 180 * 250ms = 45s.
    58                                 _cancelOnError( errorMsg );
     58                                window._cancelOnError( errorMsg );
    5959                };
    6060        }
    6161
     
    7878
    7979                // global var is used in FCK specific core
    8080                // change on equal var used in fckplugin.js
    81                 gFCKPluginName = 'wsc';
     81                window.gFCKPluginName = 'wsc';
    8282
    8383                LangComparer.setDefaulLangCode( editor.config.defaultLanguage );
    8484
  • _source/plugins/wsc/dialogs/tmpFrameset.html

     
    2424
    2525function tryLoad()
    2626{
    27         opener = window.parent;
     27        var opener = window.parent;
    2828
    2929        // get access to global parameters
    30         var oParams = window.opener.oldFramesetPageParams;
     30        var oParams = opener.oldFramesetPageParams;
    3131
    3232        // make frameset rows string prepare
    33         var sFramesetRows = ( parseInt( oParams.firstframeh, 10 ) || '30') + ",*," + ( parseInt( oParams.thirdframeh, 10 ) || '150' ) + ',0' ;
    34         document.getElementById( 'itFrameset' ).rows = sFramesetRows ;
     33        document.getElementById( 'itFrameset' ).rows =
     34                ( parseInt( oParams.firstframeh, 10 ) || '30') + ",*," + ( parseInt( oParams.thirdframeh, 10 ) || '150' ) + ',0' ; ;
    3535
    3636        // dynamic including init frames and crossdomain transport code
    3737        // from config sproxy_js_frameset url
  • _source/plugins/uicolor/dialogs/uicolor.js

     
    1313        {
    1414                // Convert HEX representation to RGB, stripping # char.
    1515                if ( /^#/.test( color ) )
    16                         color = YAHOO.util.Color.hex2rgb( color.substr( 1 ) );
     16                        color = window.YAHOO.util.Color.hex2rgb( color.substr( 1 ) );
    1717                picker.setValue( color, true );
    1818                // Refresh picker UI.
    1919                picker.refresh( 'cke_uicolor_picker' );
     
    4242                                );
    4343
    4444                        // Create new color picker widget.
    45                         picker = new YAHOO.widget.ColorPicker( "cke_uicolor_picker",
     45                        picker = new window.YAHOO.widget.ColorPicker( "cke_uicolor_picker",
    4646                                {
    4747                                        showhsvcontrols : true,
    4848                                        showhexcontrols : true,
  • CHANGES.html

     
    161161                        ckeditor2.html test case.</li>
    162162                <li><a href="http://dev.fckeditor.net/ticket/3989">#3989</a> : Host page horizontal scrolling a lot when on having righ-to-left direction.</li>
    163163                <li><a href="http://dev.fckeditor.net/ticket/4001">#4001</a> : Create link around existing image result incorrect.</li>
     164                <li><a href="http://dev.fckeditor.net/ticket/3791">#3791</a> : Fix jslint warnings in SCAYT plugin.</li>
    164165        </ul>
    165166        <h3>
    166167                CKEditor 3.0 RC</h3>
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy