Ticket #6670: 6670.patch
File 6670.patch, 1.3 KB (added by , 13 years ago) |
---|
-
_source/plugins/bidi/plugin.js
48 48 { 49 49 var editor = evt.editor, 50 50 chromeRoot = editor.container.getChild( 1 ), 51 directionNode = getElementForDirection( evt.data.path.lastElement );51 directionNode = getElementForDirection( evt.data.path.lastElement, 1 ); 52 52 53 53 if ( directionNode && editor.lang.dir != directionNode.getComputedStyle( 'direction' ) ) 54 54 chromeRoot.addClass( 'cke_mixed_dir_content' ); … … 58 58 59 59 /** 60 60 * Returns element with possibility of applying the direction. 61 * @param node 61 * @param {CKEDITOR.dom.node} node 62 * @param {boolean} includeNodesWithDirection If set to TRUE, includes nodes that already have direction, 63 * although inline elements are skipped. 62 64 */ 63 function getElementForDirection( node )65 function getElementForDirection( node, includeNodesWithDirection ) 64 66 { 65 while ( node && !( node.getName() in allGuardElements || node.is( 'body' ) ) ) 67 while ( node && !( node.getName() in allGuardElements || node.is( 'body' ) ) 68 && !( includeNodesWithDirection && node.getDirection() && !CKEDITOR.dtd.$inline[ node.getName() ] ) ) 66 69 { 67 70 var parent = node.getParent(); 68 71 if ( !parent )