X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=_source%2Fplugins%2Findent%2Fplugin.js;h=d175e46664ca8e98845235d3c91e4defab26d31b;hp=d61e6a691868358f280f350408c92a025c575e34;hb=8665a7c6c60586526e32e8941fe2896739b6ebfb;hpb=e7789c1ad838194d45eeee6ac2eb6e55f5cf35a1 diff --git a/_source/plugins/indent/plugin.js b/_source/plugins/indent/plugin.js index d61e6a6..d175e46 100644 --- a/_source/plugins/indent/plugin.js +++ b/_source/plugins/indent/plugin.js @@ -11,6 +11,9 @@ For licensing, see LICENSE.html or http://ckeditor.com/license { var listNodeNames = { ol : 1, ul : 1 }; + var isNotWhitespaces = CKEDITOR.dom.walker.whitespaces( true ), + isNotBookmark = CKEDITOR.dom.walker.bookmark( false, true ); + function setState( editor, state ) { editor.getCommand( this.name ).setState( state ); @@ -187,6 +190,11 @@ For licensing, see LICENSE.html or http://ckeditor.com/license followingList.is && followingList.getName() in listNodeNames ) { + // IE requires a filler NBSP for nested list inside empty list item, + // otherwise the list item will be inaccessiable. (#4476) + if ( CKEDITOR.env.ie && !li.getFirst( function( node ){ return isNotWhitespaces( node ) && isNotBookmark( node ); } ) ) + li.append( range.document.createText( '\u00a0' ) ); + li.append( followingList ); }