use of org.ovirt.engine.ui.uicommonweb.models.ErrataFilterValue in project ovirt-engine by oVirt.
the class ErrataFilterPanel method addValueChangeHandler.
public void addValueChangeHandler(final ValueChangeHandler<ErrataFilterValue> handler) {
ValueChangeHandler<Boolean> internalHandler = event -> {
// Do this deferred to give the javascript time to activate/deactivate the buttons.
Scheduler.get().scheduleDeferred(() -> {
// one of the checkboxes changed, but get all three checkbox values for the event
ErrataFilterValue value = new ErrataFilterValue(securityCheckbox.isActive(), bugCheckbox.isActive(), enhancementCheckbox.isActive());
handler.onValueChange(new ValueChangeEvent<ErrataFilterValue>(value) {
});
});
};
securityCheckbox.addValueChangeHandler(internalHandler);
bugCheckbox.addValueChangeHandler(internalHandler);
enhancementCheckbox.addValueChangeHandler(internalHandler);
}
Aggregations