Ticket #2765: 2765_5.patch

File 2765_5.patch, 2.4 KB (added by Garry Yao, 15 years ago)
  • _source/core/htmlparser/element.js

     
    113113                        {
    114114                                var attrib = attribsArray[ i ];
    115115                                // IE's treated expand fields as dom attributes, skip it
    116                                 if ( CKEDITOR.env.ie && attrib === '_cke_expando' )
     116                                if ( CKEDITOR.env.ie && attrib[0] === '_cke_expando' )
    117117                                        continue;
    118118                                writer.attribute( attrib[0], attrib[1] );
    119119                        }
  • _source/plugins/fakeobjects/plugin.js

     
    88 *      in WYSIWYG mode.
    99 */
    1010
    11 (function()
     11CKEDITOR.plugins.add( 'fakeobjects',
     12                {
     13                        init : function( editor, pluginPath )
     14                        {
     15                                (function()
    1216{
    1317        var flashExtensionRegex = /\.swf($|#|\?)/i,
    1418                emptyElements = { base:1,col:1,meta:1,link:1,hr:1,br:1,param:1,img:1,area:1,input:1 },
     
    346350                                                innerParser.parse( protectedHtml );
    347351                                                protectedHtml = innerParser.output.join( '' );
    348352                                        }
     353                                       
     354                                        //Format protected html which skip plugin:wysiwyg default logic
     355                                        if ( editor.dataProcessor )
     356                                                protectedHtml = editor.dataProcessor.toDataFormat( protectedHtml );
    349357
    350358                                        this.output.push( protectedHtml );
    351359                                        return;
     
    397405                }
    398406        };
    399407
    400         CKEDITOR.plugins.add( 'fakeobjects',
    401                 {
    402                         init : function( editor, pluginPath )
    403                         {
     408})();
    404409                                editor.fakeobjects = new CKEDITOR.plugins.fakeobjects();
    405410                        }
    406411                } );
    407 })();
     412
  • _source/plugins/htmldataprocessor/plugin.js

     
    2525                // The source data is already HTML, so just return it as is.
    2626                return data;
    2727        },
    28 
    29         toDataFormat : function( element )
     28       
     29        /**
     30         *
     31         * @param {CKEDITOR.dom.element|String} source
     32         */
     33        toDataFormat : function( source )
    3034        {
    3135                var writer = this.writer,
    32                         fragment = CKEDITOR.htmlParser.fragment.fromHtml( element.getHtml() );
     36                        fragment = CKEDITOR.htmlParser.fragment.fromHtml( source.type?source.getHtml() : source);
    3337
    3438                writer.reset();
    3539
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy