project.getStyleManager().load( "appstyles.xml" );
}
public void testTable()
{
XTable table = new XTable();
// String[] cols = {"col 1", "col 2", "col 3"};
// table.addColumns( cols );
table.setStyle("base/TableData");
table.setHeaderStyle("base/TableHeading");
table.setSelectedStyle( "base/TableSelection" );
// table.setModel( createManualDatasource() );
table.setModel( createDatasource() );
table.setInteractiveTable( true );
table.setSelectedRow( 2 );
frame = new Frame( "XTable test" );
frame.setLayout(null);
frame.setSize( 640, 480 );
table.setColWidth( 0, 150 );
table.setBounds( 20, 80, 400, 200 );
table.setBackground( java.awt.Color.white );
frame.add(table);
frame.setVisible(true);
frame.show();
assertTrue( table.getSelectedRow() == 2 );
}