Ticket #5436: 5436.patch

File 5436.patch, 863 bytes (added by brooks, 13 years ago)
  • _source/plugins/wysiwygarea/plugin.js

     
    120120                        }
    121121
    122122                        range.moveToPosition( lastElement, CKEDITOR.POSITION_AFTER_END );
    123 
    124                         var next = lastElement.getNextSourceNode( true );
    125                         if ( next && next.type == CKEDITOR.NODE_ELEMENT )
    126                                 range.moveToElementEditStart( next );
    127 
     123                       
     124                        // if we inserted a block element, make the cursor jump the next editalbe element( #5436)
     125                        if ( isBlock )
     126                        {
     127                                var next = lastElement.getNextSourceNode( true );
     128                                if ( next && next.type == CKEDITOR.NODE_ELEMENT )
     129                                        range.moveToElementEditStart( next );
     130                        }
     131                       
    128132                        selection.selectRanges( [ range ] );
    129133
    130134                        if ( selIsLocked )
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy