Ticket #6226: 6226_3.patch

File 6226_3.patch, 915 bytes (added by Paweł Horzela, 14 years ago)

Patch

  • _source/plugins/styles/plugin.js

     
    775775
    776776                while ( ( block = iterator.getNextParagraph() ) )               // Only one =
    777777                {
    778                         var newBlock = getElement( this, doc );
     778                        var newBlock = getElement( this, doc, block );
    779779                        replaceBlock( block, newBlock );
    780780                }
    781781
     
    10831083                }
    10841084        }
    10851085
    1086         function getElement( style, targetDocument )
     1086        function getElement( style, targetDocument, block )
    10871087        {
    10881088                var el;
    10891089
     
    10971097
    10981098                // Create the element.
    10991099                el = new CKEDITOR.dom.element( elementName, targetDocument );
     1100               
     1101                // #6226: attributes should be copied before the new ones are applied
     1102                if ( block )
     1103                        block.copyAttributes( el );
    11001104
    11011105                return setupElement( el, style );
    11021106        }
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy