// odd/even alternate style
item.add(new SimpleAttributeModifier("class",
item.getIndex() % 2 == 0 ? "even" : "odd"));
// navigation/selection links
AjaxFallbackLink link = new IndicatingAjaxFallbackLink("nameLink") {
@Override
public void onClick(AjaxRequestTarget target) {
linkNameClicked((File) item.getModelObject(), target);
}
};
link.add(new Label("name", item.getModel()) {
@Override
public IConverter getConverter(Class type) {
return FILE_NAME_CONVERTER;
}
});