return getWidget();
}
@Override
protected Pagination createWidget() {
Pagination p = new Pagination();
p.setPageFactory(new Callback<Integer, Node>() {
@Override
public Node call(Integer param) {
PagninationItemImpl item = (PagninationItemImpl) items.get(param.intValue());
item.handleSelection();
mouseSelectedItemCallback.call(item);
return item.getNativeItem().getContent();
}
});
p.currentPageIndexProperty().addListener(new ChangeListener<Number>() {
@Override
public void changed(ObservableValue<? extends Number> observable, Number oldValue, Number newValue) {
final PagninationItemImpl item = (PagninationItemImpl) items.get(newValue.intValue());
if( mouseSelectedItemCallback != null ) {