Is there is a reason you don't pass the EventBus to your view? I
found it very simple...
private static final ButtonCell deleteButtonCell = new ButtonCell();
private static final Column<Thing, String> deleteColumn =
new Column<Thing, String>(deleteButtonCell) {
@Override
public String getValue(Thing thing) {
return "delete";
}
};
private final FieldUpdater<Thing, String> deleteFieldUpdater =
new FieldUpdater<Thing, String>() {
@Override
public void update(int index, Thing thing, String value) {
if (Window.confirm("Delete " + thing.getName() + "?" )) {
eventBus.fireEvent(new ThingDeleteEvent(thing, index));
}
}
};
deleteColumn.setFieldUpdater(deleteFieldUpdater);
On Jan 20, 4:18 am, Drew Spencer <slugmand...@gmail.com> wrote:
> Eric, do you have a way to sort the FlexTable by a particular column?
> That's gonna be an issue for me so if you have any code or tips that would
> be great. Maybe it's a case of writing a custom function? Thanks
--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
No comments:
Post a Comment