Ticket #2757: 2757.patch

File 2757.patch, 884 bytes (added by Artur Formella, 16 years ago)
  • editor/_source/classes/fckdomrange.js

     
    470470                // Also note that the node that we use for "address base" would change during backtracking.
    471471                var addrStart = this._Range.startContainer ;
    472472                var addrEnd = this._Range.endContainer ;
    473                 while ( curStart && addrStart.nodeType == 3 )
     473                while ( curStart && curStart.nodeType == 3 && addrStart.nodeType == 3 )
    474474                {
    475475                        bookmark.Start[0] += curStart.length ;
    476476                        addrStart = curStart ;
    477477                        curStart = curStart.previousSibling ;
    478478                }
    479                 while ( curEnd && addrEnd.nodeType == 3 )
     479                while ( curEnd && curEnd.nodeType == 3 && addrEnd.nodeType == 3 )
    480480                {
    481481                        bookmark.End[0] += curEnd.length ;
    482482                        addrEnd = curEnd ;
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy