Ticket #5124: 5124.patch
File 5124.patch, 1.1 KB (added by , 14 years ago) |
---|
-
_source/plugins/styles/plugin.js
350 350 351 351 var styleRange; 352 352 353 // Indicates that that some useful inline content has been found, so354 // the style should be applied.355 var hasContents;356 357 353 while ( currentNode ) 358 354 { 359 355 var applyStyle = false; … … 424 420 if ( !includedNode.$.nextSibling ) 425 421 applyStyle = true; 426 422 427 if ( !hasContents )428 hasContents = ( nodeType != CKEDITOR.NODE_TEXT || (/[^\s\ufeff]/).test( currentNode.getText() ) );429 423 } 430 424 } 431 425 else … … 439 433 } 440 434 441 435 // Apply the style if we have something to which apply it. 442 if ( applyStyle && hasContents &&styleRange && !styleRange.collapsed )436 if ( applyStyle && styleRange && !styleRange.collapsed ) 443 437 { 444 438 // Build the style element, based on the style object definition. 445 439 var styleNode = getElement( this, document );