I'm having problems using ResizeLayoutPanel inside DisclosurePanel.
I have a Datagrid into ResizeLayoutPanel, and ResizeLayaoutPanel inside DisclosurePanel. The problem is when data is loaded, If DisclosurePanel was closed, when user opens disclosurePanel it finds the table empty. If user does this action when DisclosurePanel is open, works fine.
Any idea how can I solve this problem?
This is the code:
ResizeLayoutPanel resizeLayoutPanel = new ResizeLayoutPanel();
resizeLayoutPanel.setWidth("100%");
resizeLayoutPanel.setStyleName("gwt-resizeLayoutPanel-Example");
/****CREATE COLUMNS [BEGIN] ***************************************************************************/
// Create column.
TextColumn<Object> column = new TextColumn<Object>() {
@Override
public String getValue(Object object) {
return "Test";
}
};
/******CREATE COLUMNS [END] ***************************************************************************/
cellTable = new DataGrid<Object>();
cellTable.addColumn(column, "Example");
cellTable.setKeyboardSelectionPolicy(HasKeyboardSelectionPolicy.KeyboardSelectionPolicy.BOUND_TO_SELECTION);
cellTable.setWidth("100%");
cellTable.setEmptyTableWidget(new Label("Example table"));
resizeLayoutPanel.add(cellTable);
//Link dataProvider with CellTable
dataProvider.addDataDisplay(cellTable);
this.container = ModuleContainer.getAdvancedDisclosurePanel("Samples");
this.container.setWidth("100%");
this.container.setContent(resizeLayoutPanel);
return this.container;