diff --git a/js/wwwsqldesigner.js b/js/wwwsqldesigner.js index 618fd9d..a7b075b 100644 --- a/js/wwwsqldesigner.js +++ b/js/wwwsqldesigner.js @@ -348,12 +348,12 @@ SQL.Row.prototype.toXML = function() { var t = this.getTitle().replace(/"/g,"""); var nn = (this.data.nll ? "1" : "0"); var ai = (this.data.ai ? "1" : "0"); - xml += ''; + xml += '\n'; var elm = this.getDataType(); var t = elm.getAttribute("sql"); if (elm.getAttribute("length") == "1" && this.data.size) { t += "("+this.data.size+")"; } - xml += ""+t+""; + xml += ""+t+"\n"; if (this.data.def || this.data.def === null) { var q = elm.getAttribute("quote"); @@ -369,15 +369,15 @@ SQL.Row.prototype.toXML = function() { for (var i=0;i'; + xml += '\n'; } if (this.data.comment) { var escaped = this.data.comment.replace(/&/g, "&").replace(/>/g, ">").replace(/"; + xml += ""+escaped+"\n"; } - xml += ""; + xml += "\n"; return xml; } @@ -800,7 +800,7 @@ SQL.Table.prototype.down = function(e) { /* mousedown - start drag */ SQL.Table.prototype.toXML = function() { var t = this.getTitle().replace(/"/g,"""); var xml = ""; - xml += ''; + xml += '
\n'; for (var i=0;i/g, ">").replace(/"; + xml += ""+c+"\n"; } - xml += "
"; + xml += "\n"; return xml; } @@ -965,12 +965,12 @@ SQL.Key.prototype.getLabel = function() { SQL.Key.prototype.toXML = function() { var xml = ""; - xml += ''; + xml += '\n'; for (var i=0;i'; + xml += ''+r.getTitle()+'\n'; } - xml += ''; + xml += '\n'; return xml; } @@ -1352,6 +1352,7 @@ SQL.TableManager.prototype.init = function(owner) { SQL.TableManager.prototype.addRow = function(e) { var newrow = this.selected.addRow(_("newrow")); this.owner.rowManager.select(newrow); + newrow.expand(); } SQL.TableManager.prototype.select = function(table) { /* activate table */ @@ -2211,8 +2212,8 @@ SQL.Designer.prototype.findNamedTable = function(name) { /* find row specified a } SQL.Designer.prototype.toXML = function() { - var xml = ''; - xml += ''; + var xml = '\n'; + xml += '\n'; /* serialize datatypes */ if (window.XMLSerializer) { @@ -2227,7 +2228,7 @@ SQL.Designer.prototype.toXML = function() { for (var i=0;i