// Here we can add empty row for nice data loading visualisation.
}
showStatusPanel(FrameworkLocale.messages().loading());
dataSource.selectCount(params, new AsyncCallback() {
public void onFailure(Throwable caught) {
if (!parentWindow.isHidden()) {
pager.setErrorMessage(FrameworkLocale.messages().asyncerror_loadrowscount());
throw new AsyncCallbackFailureException(FrameworkLocale.messages().asyncerror_loadrowscount(), caught);
}
}
public void onSuccess(Object result) {
if (!parentWindow.isHidden()) {
pager.setTotalCount(((Integer)result).intValue());
pager.refresh();
}
}
});
dataSource.select(params, new AsyncCallback() {
public void onFailure(Throwable caught) {
if (!parentWindow.isHidden()) {
showStatusPanel((FrameworkLocale.messages().asyncerror_loadrows()));
throw new AsyncCallbackFailureException(FrameworkLocale.messages().asyncerror_loadrows(), caught);
}