Index: /FCKeditor/trunk/editor/_source/internals/fcktablehandler.js
===================================================================
--- /FCKeditor/trunk/editor/_source/internals/fcktablehandler.js	(revision 674)
+++ /FCKeditor/trunk/editor/_source/internals/fcktablehandler.js	(revision 675)
@@ -325,5 +325,4 @@
 FCKTableHandler.MergeDown = function()
 {
-	// TODO: the positional index algorithm is not accurate, use table map instead.
 	if ( ! FCKBrowserInfo.IsIE )
 	{
@@ -339,22 +338,10 @@
 	if ( isNaN( currentRowSpan ) )
 		currentRowSpan = 1 ;
-	var nextRow = currentCell.parentNode.parentNode.rows[currentCell.parentNode.rowIndex + currentRowSpan ] ;
+	var nextRow = currentCell.parentNode.parentNode.rows[currentCell.parentNode.rowIndex + currentRowSpan] ;
 	if ( nextRow )
 	{
-		var positionalIndex = FCKDomTools.GetPositionalCellIndex( currentCell ) ;
-		var equivalentCell = null ;
-		var equivalentPositionalIndex = 0 ;
-		for ( var i = 0 ; i < nextRow.cells.length ; i++ )
-		{
-			var colSpan = nextRow.cells[i].colSpan ;
-			if ( isNaN( colSpan ) )
-				colSpan = 1 ;
-			equivalentPositionalIndex += colSpan ;
-			if ( equivalentPositionalIndex >= positionalIndex )
-			{
-				equivalentCell = nextRow.cells[i] ;
-				break ;
-			}
-		}
+		var tableMap = this._CreateTableMap( currentCell.parentNode.parentNode ) ;
+		var cellIndex = FCKTableHandler._GetCellIndexSpan( tableMap, currentCell.parentNode.rowIndex, currentCell ) ;
+		var equivalentCell = tableMap[currentCell.parentNode.rowIndex + currentRowSpan][cellIndex] ;
 
 		if ( ! equivalentCell )
@@ -425,8 +412,8 @@
 	{
 		// 1. Set the current cell's rowSpan to 1.
-		currentCell.rowSpan = 1 ;
+		currentCell.rowSpan = Math.ceil( currentRowSpan / 2 ) ;
 
 		// 2. Find the appropriate place to insert a new cell at the next row.
-		var newCellRowIndex = currentRowIndex + 1 ;
+		var newCellRowIndex = currentRowIndex + Math.ceil( currentRowSpan / 2 ) ;
 		var insertMarker = null ;
 		for ( var i = cellIndex+1 ; i < tableMap[newCellRowIndex].length ; i++ )
@@ -441,5 +428,5 @@
 		// 3. Insert the new cell to the indicated place, with the appropriate rowSpan, next row.
 		var newCell = FCK.EditorDocument.createElement( 'td' ) ;
-		newCell.rowSpan = currentRowSpan - 1 ;
+		newCell.rowSpan = Math.floor( currentRowSpan / 2 ) ;
 		if ( FCKBrowserInfo.IsGecko )
 			FCKTools.AppendBogusBr( newCell ) ;
