/**
* @file InterfazJugador.java
* @brief Archivo que contiene la clase InterfazJugador.java
*
* @author Carlos Rabelo
* @version 2.2
*/
package Interfaz;
import Controladores.ControladorJugador;
import java.awt.Color;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import javax.swing.JFrame;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;
/**
* Interfaz gráfica para gestionar la clase Jugador.
*
* La clase tiene todos los elementos gráficos necesarios para mostrar
* los datos de una instancia de la clase Jugador.
* Se implementa siguiendo el patrón de Diseño "Singleton"
*
* @author Carlos Rabelo
* @version 2.2
*/
public class InterfazJugador extends javax.swing.JPanel {
private static InterfazJugador Instancia = null;
private Boolean es_gestor;
private Integer accion; // 0=Ninguna, 1=Añadir, 2=Buscar, 3=Modificar
private Boolean mostrar_tabla;
private InterfazEstadisticas interfaz_estadisticas = null;
/**
* Constructor por defecto. Al ser un singleton el contructor es privado
* @param void
* @return void
*/
public InterfazJugador() {
initComponents();
//controlador=JugadorBD.getInstancia();
}
/**
* Método que devuelve la única instancia de la clase
* @param void
* @return Instancia
*/
public static InterfazJugador getInstancia() {
if (Instancia==null){
Instancia = new InterfazJugador();
}
return Instancia;
}
@Override
/**
* Sobrecarga del método clone para impedir que se duplique la instancia
* (Exigencias del patrón Singleton)
* @param void
* @return Object
*/
public Object clone() throws CloneNotSupportedException {
throw new CloneNotSupportedException();
}
/**
* Método que inicializa los objetos de la interfaz al que debe ser
* su estado inicial, actualiza también el atributo es_gestor.
* @param esgestor Boolean indicando si el usuario activo es un gestor o no.
* @return void
*/
public void inicializar(Boolean esgestor){
es_gestor=esgestor;
if (es_gestor){
this.Boton_Nuevo.setVisible(true);
} else {
this.Boton_Nuevo.setVisible(false);
}
this.Boton_Cancelar.setVisible(false);
this.Boton_Guardar.setVisible(false);
this.PanelTablaJugadores.setVisible(false);
this.set_Editable(false);
this.mostrar_tabla=false;
this.limpiar();
this.limpiarErrores();
}
/**
* Método set para el atributo mostrar_tabla
* @param valor Boolean
* @return void
*/
public void set_MostrarTabla(Boolean valor){
mostrar_tabla=valor;
}
/**
* Método que modifica el número de filas del objeto jTable de la interfaz.
* @param filas Nuevo número de filas
* @return void
*/
public void set_Filas_Tabla(int filas){
DefaultTableModel temp = (DefaultTableModel) TablaJugadores.getModel();
int oldfilas=TablaJugadores.getRowCount();
if (oldfilas<filas){ // Añadir filas
for (int i=oldfilas; i<filas; i++){
Object nuevo[] = {i + 1, "", ""};
temp.addRow(nuevo);
}
} else if(oldfilas>filas){ // Eliminar filas
for (int i=oldfilas; i>filas; i--){
temp.removeRow(temp.getRowCount()-1);
}
}
}
/**
* Método que muestra un nombre y unos apellidos en una fila de la tabla
* @param fila número de fila en la que mostrar los datos
* @param Nombre Nombre a mostrar en la primera columna de la fila
* @param Apellidos Apellidos a mostrar en la primera columna de la fila
* @return void
*/
public void add_Jugador_Tabla(int fila, String Nombre, String Apellidos){
this.TablaJugadores.setValueAt(Nombre, fila, 0);
this.TablaJugadores.setValueAt(Apellidos, fila, 1);
}
/**
* Método que modifica la propiedad de edición del formulario
* @param editar Boolean
* @return void
*/
public void set_Editable(Boolean editar) {
jCheckBox1.setEnabled(editar);
TallaCombo.setEnabled(editar);
jRadioButton1.setEnabled(editar);
jRadioButton2.setEnabled(editar);
RadioSexoM.setEnabled(editar);
RadioSexoF.setEnabled(editar);
RadioEstadoActivo.setEnabled(editar);
RadioEstadoBaja.setEnabled(editar);
Texto_Observaciones.setEditable(editar);
Texto_Nombre.setEditable(editar);
Texto_Apellidos.setEditable(editar);
jCalendarCombo1.setEnabled(editar);
Texto_NombreTutor.setEditable(editar);
Texto_NumCuenta.setEditable(editar);
Texto_ClubAnterior.setEditable(editar);
Texto_Email.setEditable(editar);
Texto_Telefono.setEditable(editar);
Texto_Observaciones.setEditable(editar);
jRadioButton1.setEnabled(editar);
jRadioButton2.setEnabled(editar);
}
/**
* Método que limpia el contenido del formulario
* @param void
* @return void
*/
public void limpiar() {
jCheckBox1.setSelected(false);
TallaCombo.setSelectedIndex(4);
jRadioButton1.setSelected(false);
jRadioButton2.setSelected(false);
Sexo_buttonGroup.clearSelection();
Pago_buttonGroup.clearSelection();
Estado_buttonGroup.clearSelection();
Texto_Observaciones.setText("");
Texto_Nombre.setText("");
Texto_Apellidos.setText("");
Texto_NombreTutor.setText("");
Texto_NumCuenta.setText("");
Texto_ClubAnterior.setText("");
Texto_Email.setText("");
Texto_Telefono.setText("");
Texto_Observaciones.setText("");
SimpleDateFormat formatter = new SimpleDateFormat("DD-MM-yyyy");
try {
jCalendarCombo1.setDate(formatter.parse("01-01-2000"));
} catch (ParseException ex) {
//Logger.getLogger(ControladorJugador.class.getName()).log(Level.SEVERE, null, ex);
}
}
/**
* Método que muestra/oculta los objetos no necesarios para un búsqueda
* @param estado Boolean
* @return void
*/
public void set_Modo_Busqueda(Boolean estado) {
jCheckBox1.setVisible(!estado);
TallaCombo.setVisible(!estado);
jRadioButton1.setVisible(!estado);
jRadioButton2.setVisible(!estado);
Etiqueta_Sexo.setVisible(!estado);
RadioSexoM.setVisible(!estado);
RadioSexoF.setVisible(!estado);
Etiqueta_Estado.setVisible(!estado);
RadioEstadoActivo.setVisible(!estado);
RadioEstadoBaja.setVisible(!estado);
Texto_Observaciones.setVisible(!estado);
Etiqueta_Nacimiento.setVisible(!estado);
jCalendarCombo1.setVisible(!estado);
Etiqueta_NombreTutor.setVisible(!estado);
Texto_NombreTutor.setVisible(!estado);
Etiqueta_NumCuenta.setVisible(!estado);
Texto_NumCuenta.setVisible(!estado);
Texto_ClubAnterior.setVisible(!estado);
Etiqueta_Email.setVisible(!estado);
Texto_Email.setVisible(!estado);
Etiqueta_Telefono.setVisible(!estado);
Texto_Telefono.setVisible(!estado);
Etiqueta_Club_Anterior.setVisible(!estado);
this.Etiqueta_Talla.setVisible(!estado);
Etiqueta_Observaciones.setVisible(!estado);
Texto_Observaciones.setVisible(!estado);
jRadioButton1.setVisible(!estado);
jRadioButton2.setVisible(!estado);
//editable=estado;
this.PanelTablaJugadores.setVisible(!estado && mostrar_tabla);
}
/**
* Método que muestra los datos de un jugador en la interfaz
* @param nombre Nombre del jugador
* @param apellidos Apellidos del jugador
* @param sexo Sexo del jugador
* @param fecha Fecha de nacimiento del jugador
* @param talla Talla del jugador
* @param tutor Nombre del tutor del jugador
* @param correo Correo electrónico del jugador
* @param numcuenta Número de cuenta del jugador
* @param telefono Teléfono del jugador
* @param estado Estado (activo o baja) del jugador
* @return void
*/
public void mostrarJugador(String nombre, String apellidos, char sexo, Date fecha, String talla, String tutor, String correo, String numcuenta, Integer telefono, String observaciones, char formapago, Boolean estado) {
Texto_Nombre.setText(nombre);
Texto_Apellidos.setText(apellidos);
if (sexo=='M'){
RadioSexoM.setSelected(true);
} else
{
RadioSexoF.setSelected(true);
}
TallaCombo.setSelectedItem(talla);
jCalendarCombo1.setDate(fecha);
//Texto_FNacimiento.setText("");
Texto_NombreTutor.setText(tutor);
Texto_NumCuenta.setText(numcuenta);
Texto_ClubAnterior.setText("");
Texto_Email.setText(correo);
Texto_Telefono.setText(telefono.toString());
jCheckBox1.setSelected(false);
if (estado=true)
{
RadioEstadoActivo.setSelected(true);
} else
{
RadioEstadoBaja.setSelected(true);
}
// jRadioButton1.setSelected(false);
// jRadioButton2.setSelected(false);
Texto_Observaciones.setText(observaciones);
PanelTablaJugadores.setVisible(mostrar_tabla);
if (formapago=='P'){
jRadioButton1.setSelected(true);
} else
{
jRadioButton2.setSelected(true);
}
}
/**
* Método que carga los datos presentes en la interfaz y los devuelve como
* un vector de String
* @param void
* @return String[] conteniendo los datos presentes en la interfaz
*/
public String[] cargarDatosFormulario() {
String [] Datos=new String[12];
Datos[0]=this.Texto_Nombre.getText();
Datos[1]=Texto_Apellidos.getText();
if (RadioSexoM.isSelected())
{
Datos[2]="M";
} else if (RadioSexoF.isSelected())
{
Datos[2]="F";
} else {
Datos[2]=null;
}
SimpleDateFormat formatter = new SimpleDateFormat("DD-MM-yyyy");
Datos[3]=formatter.format(jCalendarCombo1.getDate());
//Datos[3]=jCalendarCombo1.getDate().toString();
Datos[4]=TallaCombo.getSelectedItem().toString();
Datos[5]=Texto_NombreTutor.getText();
Datos[6]=Texto_Email.getText();
Datos[7]=Texto_NumCuenta.getText();
Datos[8]=Texto_Telefono.getText();
if (RadioEstadoActivo.isSelected()) {
Datos[9]="activo";
} else if (RadioEstadoBaja.isSelected()){
Datos[9]="baja";
} else {
Datos[9]=null;
}
Datos[10] = Texto_Observaciones.getText();
if (jRadioButton1.isSelected())
{
Datos[11]="P";
} else if (jRadioButton2.isSelected())
{
Datos[11]="M";
} else {
Datos[11]=null;
}
return Datos;
}
/**
* Método que cambia de color las etiquetas de la interfaz, si el parámetro
* es true el color seleccionado es rojo, si el parámetro es false el color
* es negro. Se utiliza para marcar donde están los datos que son erróneos.
* @param nombre Boolean
* @param apellidos Boolean
* @param sexo Boolean
* @param fecha Boolean
* @param talla Boolean
* @param tutor Boolean
* @param correo Boolean
* @param numcuenta Boolean
* @param telefono Boolean
* @param estado Boolean
* @return void
*/
public void marcarErrores(Boolean nombre, Boolean apellidos, Boolean sexo, Boolean fecha, Boolean talla, Boolean tutor, Boolean correo, Boolean numcuenta, Boolean telefono, Boolean estado, Boolean formapago)
{
if (nombre) {
Etiqueta_Nombre.setForeground(Color.red);
} else {
Etiqueta_Nombre.setForeground(Color.black);
}
if (apellidos) {
Etiqueta_Apellidos.setForeground(Color.red);
} else {
Etiqueta_Apellidos.setForeground(Color.black);
}
if (sexo) {
Etiqueta_Sexo.setForeground(Color.red);
} else {
Etiqueta_Sexo.setForeground(Color.black);
}
if (fecha) {
Etiqueta_Nacimiento.setForeground(Color.red);
} else {
Etiqueta_Nacimiento.setForeground(Color.black);
}
if (talla) {
Etiqueta_Talla.setForeground(Color.red);
} else {
Etiqueta_Talla.setForeground(Color.black);
}
if (tutor) {
Etiqueta_NombreTutor.setForeground(Color.red);
} else {
Etiqueta_NombreTutor.setForeground(Color.black);
}
if (correo) {
Etiqueta_Email.setForeground(Color.red);
} else {
Etiqueta_Email.setForeground(Color.black);
}
if (numcuenta) {
Etiqueta_NumCuenta.setForeground(Color.red);
} else {
Etiqueta_NumCuenta.setForeground(Color.black);
}
if (telefono) {
Etiqueta_Telefono.setForeground(Color.red);
} else {
Etiqueta_Telefono.setForeground(Color.black);
}
if (estado) {
Etiqueta_Estado.setForeground(Color.red);
} else {
Etiqueta_Estado.setForeground(Color.black);
}
if (formapago) {
jRadioButton1.setForeground(Color.red);
} else {
jRadioButton2.setForeground(Color.black);
}
}
/**
* Este método llama a marcarErrores() para volver a poner todas las
* etiquetas en negro
* @param void
* @return void
*/
public void limpiarErrores(){
this.marcarErrores(false, false, false, false, false, false, false, false, false, false,false);
}
/**
* Método que modifica la visibilidad de los botones Guardar y Cancelar
* @param estado
* @return void
*/
public void setVisibleGuardarCancelar(Boolean estado) {
this.Boton_Guardar.setVisible(estado);
this.Boton_Cancelar.setVisible(estado);
}
/**
* Método que modifica la visibilidad de los botones Nuevo Buscar y Modificar
* @param estado
* @return void
*/
public void activarBotones(Boolean estado) {
Boton_Nuevo.setEnabled(estado);
Boton_Buscar.setEnabled(estado);
Boton_Modificar.setEnabled(estado);
jButton_ConsEstadisticas.setEnabled(true);
}
/**
* Método que muestra un mensaje al usuario
* @param mensaje String con el contenido del mensaje
* @param tituto String con el título de la ventana de mensaje
* @param tipo int con el tipo de icono a mostrar en el mensaje
* @return void
*/
public void mostrarMensaje(String mensaje, String titulo, int tipo) {
//JOptionPane.showConfirmDialog(null, mensaje, titulo, tipo);
JOptionPane.showMessageDialog(null, mensaje, titulo, tipo);
}
/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
Sexo_buttonGroup = new javax.swing.ButtonGroup();
Pago_buttonGroup = new javax.swing.ButtonGroup();
Estado_buttonGroup = new javax.swing.ButtonGroup();
jPanel1 = new javax.swing.JPanel();
Etiqueta_Nombre = new javax.swing.JLabel();
Etiqueta_Apellidos = new javax.swing.JLabel();
Etiqueta_Nacimiento = new javax.swing.JLabel();
Etiqueta_NombreTutor = new javax.swing.JLabel();
Texto_Nombre = new javax.swing.JTextField();
Texto_Apellidos = new javax.swing.JTextField();
Texto_NombreTutor = new javax.swing.JTextField();
Etiqueta_Club_Anterior = new javax.swing.JLabel();
Etiqueta_NumCuenta = new javax.swing.JLabel();
Etiqueta_Talla = new javax.swing.JLabel();
Etiqueta_Email = new javax.swing.JLabel();
Texto_NumCuenta = new javax.swing.JTextField();
Texto_ClubAnterior = new javax.swing.JTextField();
Texto_Email = new javax.swing.JTextField();
Etiqueta_Telefono = new javax.swing.JLabel();
Texto_Telefono = new javax.swing.JTextField();
jCheckBox1 = new javax.swing.JCheckBox();
jRadioButton1 = new javax.swing.JRadioButton();
jRadioButton2 = new javax.swing.JRadioButton();
Etiqueta_Observaciones = new javax.swing.JLabel();
jScrollPane1 = new javax.swing.JScrollPane();
Texto_Observaciones = new javax.swing.JTextArea();
Etiqueta_Sexo = new javax.swing.JLabel();
RadioSexoM = new javax.swing.JRadioButton();
RadioSexoF = new javax.swing.JRadioButton();
Etiqueta_Estado = new javax.swing.JLabel();
RadioEstadoActivo = new javax.swing.JRadioButton();
RadioEstadoBaja = new javax.swing.JRadioButton();
TallaCombo = new javax.swing.JComboBox();
jCalendarCombo1 = new org.freixas.jcalendar.JCalendarCombo();
IconoFCB = new javax.swing.JLabel();
Titulo_JPanel = new javax.swing.JLabel();
IconoTecnoSoft = new javax.swing.JLabel();
Boton_Buscar = new javax.swing.JButton();
Boton_Modificar = new javax.swing.JButton();
Boton_Nuevo = new javax.swing.JButton();
Boton_Guardar = new javax.swing.JButton();
Boton_Cancelar = new javax.swing.JButton();
PanelTablaJugadores = new javax.swing.JScrollPane();
TablaJugadores = new javax.swing.JTable();
jButton_ConsEstadisticas = new javax.swing.JButton();
jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Jugador"));
jPanel1.setMaximumSize(new java.awt.Dimension(647, 343));
jPanel1.setMinimumSize(new java.awt.Dimension(647, 343));
Etiqueta_Nombre.setText("Nombre:");
Etiqueta_Apellidos.setText("Apellidos:");
Etiqueta_Nacimiento.setText("F.Nacimiento:");
Etiqueta_NombreTutor.setText("Nombre padre/madre/tutor:");
Texto_Nombre.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Texto_NombreActionPerformed(evt);
}
});
Etiqueta_Club_Anterior.setText("Club Anterior:");
Etiqueta_NumCuenta.setText("Num.Cuenta:");
Etiqueta_Talla.setText("Talla:");
Etiqueta_Email.setText("E-mail:");
Texto_ClubAnterior.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Texto_ClubAnteriorActionPerformed(evt);
}
});
Etiqueta_Telefono.setText("Teléfono:");
Texto_Telefono.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Texto_TelefonoActionPerformed(evt);
}
});
jCheckBox1.setText("Equipación Entregada");
jCheckBox1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jCheckBox1ActionPerformed(evt);
}
});
Pago_buttonGroup.add(jRadioButton1);
jRadioButton1.setText("Un solo pago");
jRadioButton1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jRadioButton1ActionPerformed(evt);
}
});
Pago_buttonGroup.add(jRadioButton2);
jRadioButton2.setText("Pago fraccionado");
jRadioButton2.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jRadioButton2ActionPerformed(evt);
}
});
Etiqueta_Observaciones.setText("Observaciones:");
Texto_Observaciones.setColumns(20);
Texto_Observaciones.setRows(5);
jScrollPane1.setViewportView(Texto_Observaciones);
Etiqueta_Sexo.setText("Sexo:");
Sexo_buttonGroup.add(RadioSexoM);
RadioSexoM.setText("M");
RadioSexoM.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
RadioSexoMActionPerformed(evt);
}
});
Sexo_buttonGroup.add(RadioSexoF);
RadioSexoF.setText("F");
Etiqueta_Estado.setText("Estado:");
Estado_buttonGroup.add(RadioEstadoActivo);
RadioEstadoActivo.setText("Activo");
RadioEstadoActivo.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
RadioEstadoActivoActionPerformed(evt);
}
});
Estado_buttonGroup.add(RadioEstadoBaja);
RadioEstadoBaja.setText("Baja");
TallaCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "6", "8", "10", "12", "XS", "S", "M", "L", "XL", "XXL" }));
TallaCombo.setSelectedIndex(4);
TallaCombo.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
TallaComboActionPerformed(evt);
}
});
jCalendarCombo1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "01-01-2000" }));
jCalendarCombo1.setDate(new java.util.Date(946746048000L));
jCalendarCombo1.setDateFormat(new SimpleDateFormat("dd-MM-yyyy"));
jCalendarCombo1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jCalendarCombo1ActionPerformed(evt);
}
});
javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
jPanel1.setLayout(jPanel1Layout);
jPanel1Layout.setHorizontalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGap(3, 3, 3)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(jScrollPane1)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(Etiqueta_Nombre)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_Nombre, javax.swing.GroupLayout.PREFERRED_SIZE, 123, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(18, 18, 18)
.addComponent(Etiqueta_Apellidos)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_Apellidos, javax.swing.GroupLayout.PREFERRED_SIZE, 208, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(Etiqueta_Sexo)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(RadioSexoM)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(RadioSexoF))
.addGroup(jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(Etiqueta_Email)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_Email))
.addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel1Layout.createSequentialGroup()
.addComponent(Etiqueta_NumCuenta)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_NumCuenta, javax.swing.GroupLayout.PREFERRED_SIZE, 213, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(Etiqueta_Club_Anterior)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_ClubAnterior, javax.swing.GroupLayout.PREFERRED_SIZE, 209, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(Etiqueta_Telefono)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_Telefono, javax.swing.GroupLayout.PREFERRED_SIZE, 81, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Etiqueta_Estado)
.addGap(2, 2, 2)
.addComponent(RadioEstadoActivo)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(RadioEstadoBaja))))
.addComponent(Etiqueta_Observaciones)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(jCheckBox1)
.addGap(61, 61, 61)
.addComponent(jRadioButton1)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(jRadioButton2))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(Etiqueta_Nacimiento)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jCalendarCombo1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Etiqueta_Talla)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(TallaCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(Etiqueta_NombreTutor)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(Texto_NombreTutor, javax.swing.GroupLayout.PREFERRED_SIZE, 103, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addContainerGap())))
);
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(Etiqueta_Nombre)
.addComponent(Texto_Nombre, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Etiqueta_Apellidos)
.addComponent(Texto_Apellidos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Etiqueta_Sexo)
.addComponent(RadioSexoM)
.addComponent(RadioSexoF))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(Etiqueta_Nacimiento)
.addComponent(Etiqueta_Talla)
.addComponent(Etiqueta_NombreTutor)
.addComponent(Texto_NombreTutor, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(TallaCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jCalendarCombo1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(Etiqueta_NumCuenta)
.addComponent(Texto_NumCuenta, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Etiqueta_Club_Anterior)
.addComponent(Texto_ClubAnterior, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(Etiqueta_Email)
.addComponent(Texto_Email, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Etiqueta_Telefono)
.addComponent(Texto_Telefono, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(RadioEstadoBaja)
.addComponent(RadioEstadoActivo)
.addComponent(Etiqueta_Estado))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jCheckBox1)
.addComponent(jRadioButton1)
.addComponent(jRadioButton2))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(Etiqueta_Observaciones)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
);
IconoFCB.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Recursos/FCBGranada2.PNG"))); // NOI18N
Titulo_JPanel.setFont(new java.awt.Font("Andalus", 1, 24)); // NOI18N
Titulo_JPanel.setText("FUNDACION CLUB BALONCESTO GRANADA");
IconoTecnoSoft.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Recursos/logo4_2.png"))); // NOI18N
Boton_Buscar.setText("Buscar");
Boton_Buscar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Boton_BuscarActionPerformed(evt);
}
});
Boton_Modificar.setText("Modificar");
Boton_Modificar.setEnabled(false);
Boton_Modificar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Boton_ModificarActionPerformed(evt);
}
});
Boton_Nuevo.setText("Nuevo");
Boton_Nuevo.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Boton_NuevoActionPerformed(evt);
}
});
Boton_Guardar.setText("Guardar");
Boton_Guardar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Boton_GuardarActionPerformed(evt);
}
});
Boton_Cancelar.setText("Cancelar");
Boton_Cancelar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Boton_CancelarActionPerformed(evt);
}
});
TablaJugadores.setModel(new javax.swing.table.DefaultTableModel(
new Object [][] {
{null, null},
{null, null},
{null, null},
{null, null}
},
new String [] {
"Nombre", "Apellidos"
}
) {
Class[] types = new Class [] {
java.lang.String.class, java.lang.String.class
};
boolean[] canEdit = new boolean [] {
false, false
};
public Class getColumnClass(int columnIndex) {
return types [columnIndex];
}
public boolean isCellEditable(int rowIndex, int columnIndex) {
return canEdit [columnIndex];
}
});
TablaJugadores.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
TablaJugadores.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
TablaJugadoresMouseClicked(evt);
}
});
TablaJugadores.addKeyListener(new java.awt.event.KeyAdapter() {
public void keyReleased(java.awt.event.KeyEvent evt) {
TablaJugadoresKeyReleased(evt);
}
});
PanelTablaJugadores.setViewportView(TablaJugadores);
jButton_ConsEstadisticas.setText("Estadísticas");
jButton_ConsEstadisticas.setEnabled(false);
jButton_ConsEstadisticas.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jButton_ConsEstadisticasActionPerformed(evt);
}
});
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
this.setLayout(layout);
layout.setHorizontalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addContainerGap()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addComponent(IconoFCB)
.addGap(18, 18, 18)
.addComponent(Titulo_JPanel)
.addGap(73, 73, 73)
.addComponent(IconoTecnoSoft))
.addGroup(layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addComponent(jButton_ConsEstadisticas, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)
.addComponent(Boton_Buscar, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Boton_Nuevo, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Boton_Modificar, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addGap(47, 47, 47)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addComponent(PanelTablaJugadores, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(21, 21, 21)
.addComponent(Boton_Guardar)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(Boton_Cancelar))
.addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addContainerGap()
.addComponent(IconoFCB))
.addGroup(layout.createSequentialGroup()
.addGap(40, 40, 40)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(IconoTecnoSoft)
.addComponent(Titulo_JPanel))))
.addGap(19, 19, 19)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGroup(layout.createSequentialGroup()
.addComponent(Boton_Nuevo, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(18, 18, 18)
.addComponent(Boton_Buscar, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(18, 18, 18)
.addComponent(Boton_Modificar, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(jButton_ConsEstadisticas, javax.swing.GroupLayout.PREFERRED_SIZE, 58, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(23, 23, 23)))
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(Boton_Cancelar)
.addComponent(Boton_Guardar)
.addComponent(PanelTablaJugadores, javax.swing.GroupLayout.PREFERRED_SIZE, 94, javax.swing.GroupLayout.PREFERRED_SIZE))
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
jPanel1.getAccessibleContext().setAccessibleName(null);
}// </editor-fold>//GEN-END:initComponents
private void jCheckBox1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jCheckBox1ActionPerformed
// TODO addJugador your handling code here:
}//GEN-LAST:event_jCheckBox1ActionPerformed
private void Texto_TelefonoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Texto_TelefonoActionPerformed
// TODO addJugador your handling code here:
}//GEN-LAST:event_Texto_TelefonoActionPerformed
private void jRadioButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jRadioButton1ActionPerformed
// TODO addJugador your handling code here:
}//GEN-LAST:event_jRadioButton1ActionPerformed
private void RadioEstadoActivoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_RadioEstadoActivoActionPerformed
// TODO addJugador your handling code here:
}//GEN-LAST:event_RadioEstadoActivoActionPerformed
private void Boton_BuscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Boton_BuscarActionPerformed
// TODO addJugador your handling code here:
accion=2;
// Activar la edición para la búsqueda
this.limpiar();
set_Modo_Busqueda(true);
//set_RegValido(false);
this.set_Editable(true);
this.Boton_Guardar.setText("Iniciar");
this.setVisibleGuardarCancelar(true);
this.activarBotones(false);
this.PanelTablaJugadores.setVisible(false);
this.jButton_ConsEstadisticas.setEnabled(false);
}//GEN-LAST:event_Boton_BuscarActionPerformed
private void Boton_ModificarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Boton_ModificarActionPerformed
// TODO addJugador your handling code here:
accion=3;
this.set_Editable(true);
this.Boton_Guardar.setText("Modificar");
this.setVisibleGuardarCancelar(true);
this.activarBotones(false);
this.PanelTablaJugadores.setVisible(false);
}//GEN-LAST:event_Boton_ModificarActionPerformed
private void Boton_NuevoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Boton_NuevoActionPerformed
// TODO addJugador your handling code here:
accion=1;
this.limpiar();
this.set_Editable(true);
this.Boton_Guardar.setText("Guardar");
this.setVisibleGuardarCancelar(true);
this.activarBotones(false);
this.PanelTablaJugadores.setVisible(false);
//ControladorJugador.getInstancia().addJugador(1);
}//GEN-LAST:event_Boton_NuevoActionPerformed
private void Boton_GuardarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Boton_GuardarActionPerformed
// TODO addJugador your handling code here:
if (accion==1) { // Se esta intentando guardar un nuevo jugador
// Captar informacion del formulario y enviarla al controlador
System.out.println("REsultado 0");
if (ControladorJugador.getInstancia().addJugador(this.cargarDatosFormulario())){
// Accion concluida con éxito. Restaurar interfaz
System.out.println("REsultado 1");
accion=0;
this.set_Editable(false);
this.setVisibleGuardarCancelar(false);
this.activarBotones(true);
} // Si no, dejar como está
} else if (accion==2) { // Se va a iniciar la búsqueda
// Captar informacion del formulario y enviarla al controlador
String [] Datos = new String[2];
Datos[0] = this.Texto_Nombre.getText();
Datos[1] = this.Texto_Apellidos.getText();
if (ControladorJugador.getInstancia().getJugador(Datos)){
// Accion concluida con éxito. Restaurar interfaz
accion=0;
set_Modo_Busqueda(false);
this.set_Editable(false);
this.setVisibleGuardarCancelar(false);
this.activarBotones(true);
} // Si no, dejar como está
} else if (accion==3) { // Se va a intentar modificar un jugador
// Captar informacion del formulario y enviarla al controlador
if (ControladorJugador.getInstancia().updateJugador(this.cargarDatosFormulario())){
System.out.println("REsultado 2");
// Accion concluida con éxito. Restaurar interfaz
accion=0;
this.set_Editable(false);
this.setVisibleGuardarCancelar(false);
this.activarBotones(true);
if (ControladorJugador.getInstancia().refrescar(null)){
this.Boton_Modificar.setEnabled(true);
this.add_Jugador_Tabla(this.TablaJugadores.getSelectedRow(), this.Texto_Nombre.getText(), this.Texto_Apellidos.getText());
} else {
this.limpiar();
this.Boton_Modificar.setEnabled(false);
}
} // Si no, dejar como está
}
}//GEN-LAST:event_Boton_GuardarActionPerformed
private void Boton_CancelarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Boton_CancelarActionPerformed
// TODO addJugador your handling code here:
//if (accion==1) { // Se estaba intentando guardar un nuevo jugador
// Restaurar interfaz
accion=0;
set_Modo_Busqueda(false);
this.set_Editable(false);
this.setVisibleGuardarCancelar(false);
this.activarBotones(true);
if (ControladorJugador.getInstancia().refrescar(null)){
this.Boton_Modificar.setEnabled(true);
} else {
this.limpiar();
this.Boton_Modificar.setEnabled(false);
}
//}
//ControladorJugador.getInstancia().addJugador(5);
/*
if (registro_valido) {
// Restaurar valores (se estaba modificando)
if (jugadores.length>1){
setVisibleAnteriorSiguiente(true);
}
refrescarJugadorActivo();
} else {
limpiar(); // Se estaba creando un Jugador nuevo
}
set_Editable(false);
activarBotones();
setVisibleGuardarCancelar(false);
desMarcarErrores();
if (accion==2){
set_Modo_Busqueda(false);
}
accion=0;
*/
}//GEN-LAST:event_Boton_CancelarActionPerformed
private void RadioSexoMActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_RadioSexoMActionPerformed
// TODO addJugador your handling code here:
}//GEN-LAST:event_RadioSexoMActionPerformed
private void TallaComboActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_TallaComboActionPerformed
// TODO addJugador your handling code here:
}//GEN-LAST:event_TallaComboActionPerformed
private void TablaJugadoresMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_TablaJugadoresMouseClicked
// TODO add your handling code here:
ControladorJugador.getInstancia().refrescar(this.TablaJugadores.getSelectedRow());
}//GEN-LAST:event_TablaJugadoresMouseClicked
private void TablaJugadoresKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_TablaJugadoresKeyReleased
// TODO add your handling code here:
ControladorJugador.getInstancia().refrescar(this.TablaJugadores.getSelectedRow());
}//GEN-LAST:event_TablaJugadoresKeyReleased
private void jButton_ConsEstadisticasActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton_ConsEstadisticasActionPerformed
this.set_MostrarTabla(false);
if (interfaz_estadisticas == null){
interfaz_estadisticas = InterfazEstadisticas.getInstancia();
jPanel1.add(interfaz_estadisticas);
}
interfaz_estadisticas.setVisible(true);
}//GEN-LAST:event_jButton_ConsEstadisticasActionPerformed
private void jCalendarCombo1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jCalendarCombo1ActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_jCalendarCombo1ActionPerformed
private void Texto_NombreActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Texto_NombreActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_Texto_NombreActionPerformed
private void Texto_ClubAnteriorActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Texto_ClubAnteriorActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_Texto_ClubAnteriorActionPerformed
private void jRadioButton2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jRadioButton2ActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_jRadioButton2ActionPerformed
// Variables declaration - do not modify//GEN-BEGIN:variables
private javax.swing.JButton Boton_Buscar;
private javax.swing.JButton Boton_Cancelar;
private javax.swing.JButton Boton_Guardar;
private javax.swing.JButton Boton_Modificar;
private javax.swing.JButton Boton_Nuevo;
private javax.swing.ButtonGroup Estado_buttonGroup;
private javax.swing.JLabel Etiqueta_Apellidos;
private javax.swing.JLabel Etiqueta_Club_Anterior;
private javax.swing.JLabel Etiqueta_Email;
private javax.swing.JLabel Etiqueta_Estado;
private javax.swing.JLabel Etiqueta_Nacimiento;
private javax.swing.JLabel Etiqueta_Nombre;
private javax.swing.JLabel Etiqueta_NombreTutor;
private javax.swing.JLabel Etiqueta_NumCuenta;
private javax.swing.JLabel Etiqueta_Observaciones;
private javax.swing.JLabel Etiqueta_Sexo;
private javax.swing.JLabel Etiqueta_Talla;
private javax.swing.JLabel Etiqueta_Telefono;
private javax.swing.JLabel IconoFCB;
private javax.swing.JLabel IconoTecnoSoft;
private javax.swing.ButtonGroup Pago_buttonGroup;
private javax.swing.JScrollPane PanelTablaJugadores;
private javax.swing.JRadioButton RadioEstadoActivo;
private javax.swing.JRadioButton RadioEstadoBaja;
private javax.swing.JRadioButton RadioSexoF;
private javax.swing.JRadioButton RadioSexoM;
private javax.swing.ButtonGroup Sexo_buttonGroup;
private javax.swing.JTable TablaJugadores;
private javax.swing.JComboBox TallaCombo;
private javax.swing.JTextField Texto_Apellidos;
private javax.swing.JTextField Texto_ClubAnterior;
private javax.swing.JTextField Texto_Email;
private javax.swing.JTextField Texto_Nombre;
private javax.swing.JTextField Texto_NombreTutor;
private javax.swing.JTextField Texto_NumCuenta;
private javax.swing.JTextArea Texto_Observaciones;
private javax.swing.JTextField Texto_Telefono;
private javax.swing.JLabel Titulo_JPanel;
private javax.swing.JButton jButton_ConsEstadisticas;
private org.freixas.jcalendar.JCalendarCombo jCalendarCombo1;
private javax.swing.JCheckBox jCheckBox1;
private javax.swing.JPanel jPanel1;
private javax.swing.JRadioButton jRadioButton1;
private javax.swing.JRadioButton jRadioButton2;
private javax.swing.JScrollPane jScrollPane1;
// End of variables declaration//GEN-END:variables
public static void main(String args[]) {
/* Create and display the form */
java.awt.EventQueue.invokeLater(new Runnable() {
@Override
public void run() {
JFrame frame = new javax.swing.JFrame("Jugador");
frame.setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
InterfazJugador interfaz=InterfazJugador.getInstancia();
interfaz.inicializar(true);
frame.getContentPane().add(interfaz);
frame.pack();
frame.setVisible(true);
}
});
}
}