]> WPIA git - gigi.git/blobdiff - src/org/cacert/gigi/output/DataTable.java
removed debug output
[gigi.git] / src / org / cacert / gigi / output / DataTable.java
index 771a0c2a82a9f06aace35d0d1820d61a51d491da..fb4f4da6f3baab60d1ed319c63deb886c5bf34da 100644 (file)
@@ -15,8 +15,7 @@ public class DataTable implements Outputable {
                this.cells = content;
        }
 
-       @Override
-       public void output(PrintWriter out, Language l, Map<String, Object> vars) {
+       public void output(PrintWriter out, Language l) {
                int mesCells = cells.size();
                for (Cell c : cells) {
                        if (c.getColSpan() > 1) {
@@ -25,11 +24,10 @@ public class DataTable implements Outputable {
                }
                out.println("<table align=\"center\" valign=\"middle\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" class=\"wrapper\">");
                int cellsRendered = 0;
-               for (int i = 0; i < mesCells / columnCount; i++) {
+               for (int i = 0; i < (mesCells / columnCount) - 1; i++) {
                        out.println("<tr>");
                        for (int j = 0; j < columnCount;) {
-                               Cell current = cells.get(cellsRendered);
-                               cellsRendered++;
+                               Cell current = cells.get(cellsRendered++);
                                j += current.getColSpan();
                                out.println("<td " + current.getHtmlAttribs() + " >");
                                out.print(current.shouldTranslate() ? l.getTranslation(current
@@ -87,4 +85,9 @@ public class DataTable implements Outputable {
 
        }
 
+       @Override
+       public void output(PrintWriter out, Language l, Map<String, Object> vars) {
+               output(out, l);
+       }
+
 }