this.calendar = calendar;
initWidget(outer);
setStyleName("DynaTable-DayFilterWidget");
outer.add(new DayCheckBox("Sunday", 0));
outer.add(new DayCheckBox("Monday", 1));
outer.add(new DayCheckBox("Tuesday", 2));
outer.add(new DayCheckBox("Wednesday", 3));
outer.add(new DayCheckBox("Thursday", 4));
outer.add(new DayCheckBox("Friday", 5));
outer.add(new DayCheckBox("Saturday", 6));
Button buttonAll = new Button("All", new ClickListener() {
public void onClick(Widget sender) {
setAllCheckBoxes(true);
}
});
Button buttonNone = new Button("None", new ClickListener() {
public void onClick(Widget sender) {
setAllCheckBoxes(false);
}
});
HorizontalPanel hp = new HorizontalPanel();
hp.setHorizontalAlignment(HasAlignment.ALIGN_CENTER);
hp.add(buttonAll);
hp.add(buttonNone);
outer.add(hp);
outer.setCellVerticalAlignment(hp, HasAlignment.ALIGN_BOTTOM);
outer.setCellHorizontalAlignment(hp, HasAlignment.ALIGN_CENTER);