public void mostrarPanel(ModoEdicion modoEdicion) {
   try {
     this.modoEdicion = modoEdicion;
     mostrar();
   } catch (Exception ex) {
     DialogManager.mostrarError(getShell(), ex);
   }
 }
  private void mostrar() {
    try {
      cargarDatos();
      enlazarDatos();
      accionesGui();

    } catch (Exception e) {
      DialogManager.mostrarError(getShell(), e);
    }
  }
 public void setEditable(Composite composite, boolean editable) {
   try {
     Control[] controles = composite.getChildren();
     if (controles != null) {
       for (Control c : controles) {
         if (c instanceof Button && (((Button) c).getStyle() & SWT.CHECK) != 0)
           ((Button) c).setEnabled(editable);
         else if (c instanceof Text) ((Text) c).setEditable(editable);
         else if (c instanceof Combo) ((Combo) c).setEnabled(editable);
         else if (c instanceof Composite) setEditable((Composite) c, editable);
       }
     }
   } catch (Exception ex) {
     DialogManager.mostrarError(getShell(), ex);
   }
 }
 private void mostrarErroresGuardado(Exception e) {
   DialogManager.mostrarError(getShell(), e);
 }