Fixing js error in chrome when uploading images

skala
Julio Montoya 13 years ago
parent d202d8dedf
commit 2bbeffb044
  1. 15
      main/inc/lib/fckeditor/editor/_source/internals/fckselection_gecko.js

@ -183,17 +183,20 @@ FCKSelection.MoveToAncestorNode = function( nodeTagName )
var oNode ;
var oContainer = this.GetSelectedElement() ;
if ( ! oContainer )
oContainer = this.GetSelection().getRangeAt(0).startContainer ;
while ( oContainer )
{
if ( ! oContainer ) {
var selection = this.GetSelection();
if (selection.rangeCount) {
oContainer = selection.getRangeAt(0).startContainer ;
}
}
while ( oContainer ) {
if ( oContainer.nodeName.IEquals( nodeTagName ) )
return oContainer ;
oContainer = oContainer.parentNode ;
}
return null ;
return null;
}
FCKSelection.Delete = function()

Loading…
Cancel
Save