Index: /FCKeditor/trunk/editor/_source/classes/fckdomrange.js
===================================================================
--- /FCKeditor/trunk/editor/_source/classes/fckdomrange.js	(revision 802)
+++ /FCKeditor/trunk/editor/_source/classes/fckdomrange.js	(revision 803)
@@ -528,5 +528,10 @@
 
 			case 'block_contents' :
-				if ( this.StartBlock && FCKConfig.EnterMode != 'br' )
+			case 'list_contents' :
+				var boundarySet = FCKListsLib.BlockBoundaries ;
+				if ( unit == 'list_contents' )
+					boundarySet = FCKListsLib.ListBoundaries ;
+
+				if ( this.StartBlock && FCKConfig.EnterMode != 'br' && unit == 'block_contents' )
 					this.SetStart( this.StartBlock, 1 ) ;
 				else
@@ -545,9 +550,9 @@
 							&& ( oNode.nodeType != 1 
 								|| ( oNode != this.StartBlockLimit
-									&& !FCKListsLib.BlockBoundaries[ oNode.nodeName.toLowerCase() ] ) ) )
+									&& !boundarySet[ oNode.nodeName.toLowerCase() ] ) ) )
 					{
 						this._Range.setStartBefore( oNode ) ;
 						
-						if ( oNode == oNode.parentNode.firstChild && FCKListsLib.BlockBoundaries[ oNode.parentNode.nodeName.toLowerCase() ] )
+						if ( oNode == oNode.parentNode.firstChild && boundarySet[ oNode.parentNode.nodeName.toLowerCase() ] )
 							break ;
 
@@ -556,5 +561,5 @@
 				}
 
-				if ( this.EndBlock && FCKConfig.EnterMode != 'br'  )
+				if ( this.EndBlock && FCKConfig.EnterMode != 'br' && unit == 'block_contents' )
 					this.SetEnd( this.EndBlock, 2 ) ;
 				else
@@ -569,9 +574,9 @@
 							&& ( oNode.nodeType != 1 
 								|| ( oNode != this.StartBlockLimit 
-									&& !FCKListsLib.BlockBoundaries[ oNode.nodeName.toLowerCase() ] ) ) )
+									&& !boundarySet[ oNode.nodeName.toLowerCase() ] ) ) )
 					{
 						this._Range.setEndAfter( oNode ) ;
 
-						if ( oNode == oNode.parentNode.lastChild && FCKListsLib.BlockBoundaries[ oNode.parentNode.nodeName.toLowerCase() ] )
+						if ( oNode == oNode.parentNode.lastChild && boundarySet[ oNode.parentNode.nodeName.toLowerCase() ] )
 							break ;
 
@@ -584,55 +589,4 @@
 						this._Range.setEndAfter( oNode ) ;
 				}
-
-				this._UpdateElementInfo() ;
-				break ;
-
-			case 'list_contents' :
-				// Get the start node for the current range.
-				oNode = this._Range.startContainer ;
-
-				// If it is an element, get the current child node for the range (in the offset).
-				// If the offset node is not available, the the first one.
-				if ( oNode.nodeType == 1 )
-					oNode = oNode.childNodes[ this._Range.startOffset ] || oNode.firstChild ;
-
-				// We must look for the left boundary, relative to the range
-				// start, which is limited by a block element.
-				while ( oNode 
-						&& ( oNode.nodeType != 1 
-							|| ( oNode != this.StartBlockLimit
-								&& !FCKListsLib.ListBoundaries[ oNode.nodeName.toLowerCase() ] ) ) )
-				{
-					this._Range.setStartBefore( oNode ) ;
-
-					if ( oNode == oNode.parentNode.firstChild && FCKListsLib.ListBoundaries[ oNode.parentNode.nodeName.toLowerCase() ] )
-						break ;
-
-					oNode = FCKDomTools.GetPreviousSourceNode( oNode, true ) ;
-				}
-
-				oNode = this._Range.endContainer ;
-				if ( oNode.nodeType == 1 )
-					oNode = oNode.childNodes[ this._Range.endOffset ] || oNode.lastChild ;
-
-				// We must look for the right boundary, relative to the range
-				// end, which is limited by a block element.
-				while ( oNode 
-						&& ( oNode.nodeType != 1 
-							|| ( oNode != this.StartBlockLimit 
-								&& !FCKListsLib.ListBoundaries[ oNode.nodeName.toLowerCase() ] ) ) )
-				{
-					this._Range.setEndAfter( oNode ) ;
-
-					if ( oNode == oNode.parentNode.lastChild && FCKListsLib.ListBoundaries[ oNode.parentNode.nodeName.toLowerCase() ] )
-						break ;
-
-					oNode = FCKDomTools.GetNextSourceNode( oNode, true ) ;
-				}
-
-				// In EnterMode='br', the end <br> boundary element must
-				// be included in the expanded range.
-				if ( oNode && oNode.nodeName.toLowerCase() == 'br' ) 
-					this._Range.setEndAfter( oNode ) ;
 
 				this._UpdateElementInfo() ;
