this.displayableButtons.add(displayableButton);
}
if (this.displayableButtons.contains(DisplayableButton.CANCEL))
{
buttonCancel = new TextButton(getCancelButtonLabel(), new SelectEvent.SelectHandler()
{
@Override
public void onSelect(final SelectEvent event)
{
MySimpleControlsPopup.this.onButtonCancelClicked();
}
});
buttonCancel.setItemId(CANCEL);
buttonCancel.setIcon(DkMain.icons().cancel_16());
addButton(buttonCancel);
}
if (this.displayableButtons.contains(DisplayableButton.RESET))
{
buttonReset = new TextButton(getResetButtonLabel(), new SelectEvent.SelectHandler()
{
@Override
public void onSelect(final SelectEvent event)
{
MySimpleControlsPopup.this.onButtonResetClicked();
}
});
buttonReset.setItemId(RESET);
buttonReset.setIcon(DkMain.icons().refresh_16());
addButton(buttonReset);
}
if (this.displayableButtons.contains(DisplayableButton.SAVE))
{
buttonSave = new TextButton(getSaveButtonLabel(), new SelectEvent.SelectHandler()
{
@Override
public void onSelect(final SelectEvent event)
{
MySimpleControlsPopup.this.onButtonSaveClicked();
}
});
buttonSave.setItemId(SAVE);
buttonSave.setIcon(DkMain.icons().save_16());
addButton(buttonSave);
}
if (this.displayableButtons.contains(DisplayableButton.OK))
{
buttonOk = new TextButton(getOkButtonLabel(), new SelectEvent.SelectHandler()
{
@Override
public void onSelect(final SelectEvent event)
{
MySimpleControlsPopup.this.onButtonOkClicked();
}
});
buttonOk.setItemId(OK);
buttonOk.setIcon(DkMain.icons().ok_16());
addButton(buttonOk);
}
else if (this.displayableButtons.contains(DisplayableButton.SEARCH))
{
buttonSearch = new TextButton(getSearchButtonLabel(), new SelectEvent.SelectHandler()
{
@Override
public void onSelect(final SelectEvent event)
{
MySimpleControlsPopup.this.onButtonSearchClicked();