Revision: 7244 Author: jlaba...@google.com Date: Thu Dec 3 14:30:41 2009 Log: Resizing MailList to avoid unneccessary vertical scroll bar.
Patch by: jlabanca Review by: jgw http://code.google.com/p/google-web-toolkit/source/detail?r=7244 Modified: /trunk/samples/mail/src/com/google/gwt/sample/mail/client/MailList.java ======================================= --- /trunk/samples/mail/src/com/google/gwt/sample/mail/client/MailList.java Tue Nov 24 14:14:51 2009 +++ /trunk/samples/mail/src/com/google/gwt/sample/mail/client/MailList.java Thu Dec 3 14:30:41 2009 @@ -131,15 +131,6 @@ // Initialize the table. table.getColumnFormatter().setWidth(0, "128px"); table.getColumnFormatter().setWidth(1, "192px"); - - for (int i = 0; i < VISIBLE_EMAIL_COUNT; ++i) { - table.setText(i, 0, ""); - table.setText(i, 1, ""); - table.setText(i, 2, ""); - table.getCellFormatter().setWordWrap(i, 0, false); - table.getCellFormatter().setWordWrap(i, 1, false); - table.getCellFormatter().setWordWrap(i, 2, false); - } } /** @@ -208,9 +199,7 @@ // Clear any remaining slots. for (; i < VISIBLE_EMAIL_COUNT; ++i) { - table.setHTML(i, 0, " "); - table.setHTML(i, 1, " "); - table.setHTML(i, 2, " "); + table.removeRow(table.getRowCount() - 1); } } } -- http://groups.google.com/group/Google-Web-Toolkit-Contributors