Ticket #3411: 3411.patch
File 3411.patch, 1.2 KB (added by , 14 years ago) |
---|
-
_source/plugins/styles/plugin.js
521 521 if ( range.collapsed ) 522 522 { 523 523 /* 524 * If the range is collapsed, try to remove the style from all ancestor525 * elements, until a block boundary is reached.524 * If the range is collapsed, break the style parent, creating a section 525 * without the style. 526 526 */ 527 527 var startPath = new CKEDITOR.dom.elementPath( startNode.getParent() ); 528 528 for ( var i = 0, element ; i < startPath.elements.length && ( element = startPath.elements[i] ) ; i++ ) … … 531 531 break; 532 532 533 533 if ( this.checkElementRemovable( element ) ) 534 { 535 /* 536 * Before removing the style node, there may be a sibling to the style node 537 * that's exactly the same to the one to be removed. To the user, it makes 538 * no difference that they're separate entities in the DOM tree. So, merge 539 * them before removal. 540 */ 541 mergeSiblings( element ); 542 removeFromElement( this, element ); 543 } 534 startNode.breakParent(element); 544 535 } 545 536 } 546 537 else