r1750 - branches/bxe_2_0/js

[email protected] Thu, 13 Sep 2007 16:02:45 +0200 (CEST)
Newsgroups gmane.editors.bitflux.cvs
Message-ID <[email protected]>
Author: chregu
Date: Thu Sep 13 16:02:45 2007
New Revision: 1750

Log:
fix BXEB-38
add efaultcontent, if empty nextSibling


Modified:
   branches/bxe_2_0/js/table.js

Modified: branches/bxe_2_0/js/table.js
==============================================================================
--- branches/bxe_2_0/js/table.js	(original)
+++ branches/bxe_2_0/js/table.js	Thu Sep 13 16:02:45 2007
@@ -189,9 +189,15 @@
 	var nextSibling = first.nextSibling;
 	while (nextSibling && nextSibling.nodeType != 1) {
 		nextSibling = nextSibling.nextSibling;
+		
 	}
 	if (nextSibling) {
 		nextSibling.setAttribute("colspan","1");
+		nextSibling.betterNormalize();
+		if (!nextSibling.firstChild || nextSibling.firstChild.isWhitespaceOnly) {
+			nextSibling.init();
+			nextSibling.XMLNode.makeDefaultNodes();
+		}
 	}
 	return first.parentNode.parentNode;
 }
@@ -225,6 +231,11 @@
 	}
 	if (nextSibling) {
 		nextSibling.setAttribute("rowspan","1");
+		nextSibling.betterNormalize();
+		if (!nextSibling.firstChild || nextSibling.firstChild.isWhitespaceOnly) {
+			nextSibling.init();
+			nextSibling.XMLNode.makeDefaultNodes();
+		}
 	}
 	var cell = matrix[rowPos + rowspan - 1][colPos + 1];
 	if (cell) {
-- 
Bx-editor-cvs mailing list
[email protected]
http://lists.bitflux.ch/cgi-bin/listinfo/bx-editor-cvs