Changeset 825


Ignore:
Timestamp:
09/15/2007 01:25:53 PM (8 years ago)
Author:
fredck
Message:

Fixed #525 : The union if successive DIVs will work properly now if EnterMode!=div. DIV elements are now considered the Block in element paths if no Block is available (previously it was set as the BlockLimit, leaving Block=null).

Location:
FCKeditor/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • FCKeditor/trunk/_whatsnew.html

    r811 r825  
    217217                <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/68">#68</a>] The style
    218218                        system now properly handles Format styles when EnterMode=br.</li>
     219                <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/525">#525</a>] The union
     220                        if successive DIVs will work properly now if EnterMode!=div.</li>
    219221        </ul>
    220222        <h3>
  • FCKeditor/trunk/editor/_source/classes/fckelementpath.js

    r694 r825  
    4848
    4949                                if ( FCKListsLib.PathBlockLimitElements[ sElementName ] != null )
    50                                         eBlockLimit = e ;
     50                                {
     51                                        // DIV is considered the Block, if no block is available (#525).
     52                                        if ( !eBlock && sElementName == 'div' )
     53                                                eBlock = e ;
     54                                        else
     55                                                eBlockLimit = e ;
     56                                }
    5157                        }
    5258
  • FCKeditor/trunk/editor/_source/classes/fckenterkey.js

    r823 r825  
    139139        var oRange = new FCKDomRange( this.Window ) ;
    140140        oRange.MoveToSelection() ;
    141 
    142         if ( !oRange.CheckIsCollapsed() )
     141       
     142        var isCollapsed = oRange.CheckIsCollapsed() ;
     143
     144        if ( !isCollapsed )
    143145        {
    144146                // Bug #327, Backspace with an img selection would activate the default action in IE.
     
    164166        if ( oRange.StartBlockLimit == oRange.EndBlockLimit && oStartBlock && oEndBlock )
    165167        {
    166                 if ( !oRange.CheckIsCollapsed() )
     168                if ( !isCollapsed )
    167169                {
    168170                        var bEndOfBlock = oRange.CheckEndOfBlock() ;
Note: See TracChangeset for help on using the changeset viewer.
© 2003 – 2012 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy