Changeset 5100

Show
Ignore:
Timestamp:
07/11/08 16:59:56 (4 months ago)
Author:
magi@…
Message:

Updated book examples. Components inside Tables, editable Tables.

Location:
trunk/src/com/itmill/toolkit/tests/book
Files:
2 added
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/com/itmill/toolkit/tests/book/BookTestApplication.java

    r5072 r5100  
    133133                        "textfieldvalidation", "datefield", "button", 
    134134                        "select/select", "select/native", "select/optiongroup", 
    135                         "select/twincol", "filterselect", "validator", "table", "table/select", 
     135                        "select/twincol", "filterselect", "validator", "table", "table/select", "table/component", "table/paging", "table/editable", 
    136136                        "upload", "link", "gridlayout", "orderedlayout", 
    137137                        "formlayout", "form", "form/simple", "form/layout", "panel", "expandlayout", "expandlayout/root", "tabsheet", 
     
    548548     
    549549    void example_Table(Window main, String param) { 
    550         if (param != null && param.equals("select")) { 
    551             main.addComponent(new TableExample2()); 
    552         } else if (param != null && param.equals("paging")) { 
    553             PagingTable table = new PagingTable(); 
    554             table.addContainerProperty("Column 1", String.class, null); 
    555             for (int i=0; i<100; i++) 
    556                 table.addItem(new Object[]{"Item "+i}, new Integer(i)); 
    557             main.addComponent(table); 
     550        if (param != null) { 
     551            if (param.equals("select")) { 
     552                main.addComponent(new TableExample2()); 
     553            } else if (param.equals("component")) { 
     554                main.addComponent(new TableExample3()); 
     555            } else if (param.equals("editable")) { 
     556                main.addComponent(new TableEditable()); 
     557            } else if (param.equals("paging")) { 
     558                PagingTable table = new PagingTable(); 
     559                table.addContainerProperty("Column 1", String.class, null); 
     560                for (int i=0; i<100; i++) 
     561                    table.addItem(new Object[]{"Item "+i}, new Integer(i)); 
     562                main.addComponent(table); 
     563            } 
    558564        }else 
    559565            main.addComponent(new TableExample1());