public void cambiarPeriodo() { ValueHolder holder = new ValueHolder(periodo); AbstractDialog dialog = Binder.createPeriodoSelector(holder); dialog.open(); if (!dialog.hasBeenCanceled()) { periodo = (Periodo) holder.getValue(); load(); updatePeriodoLabel(); } }
/** Called when user confirms the information. */ public void doAccept() { String validationMessage = validateInformation(); if (validationMessage == null) { super.doAccept(); } else { JOptionPane.showMessageDialog( this, validationMessage, Strings.message("guide.dialog.error"), JOptionPane.ERROR_MESSAGE); } }
/** * Opens a dialog. * * @param set guides set. */ public void openDialog(GuidesSet set) { guidesSet = set; super.open(); }