public UIUnidad(IUnidad interfaz) { initComponents(); this.setVisible(true); this.setTitle("MANTENIMIENTO DE UNIDAD"); setLocationRelativeTo(null); this.interfaz = interfaz; interfaz.cargar(tblRegistros); cellSelectionModel = tblRegistros.getSelectionModel(); cellSelectionModel.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); cellSelectionModel.addListSelectionListener( new ListSelectionListener() { @Override public void valueChanged(ListSelectionEvent e) { interfaz.actualizarEst(tblRegistros, chActivar); } }); interfaz.buscarUnidad(txtBuscar, tblRegistros); }
private void searchActionPerformed( java.awt.event.ActionEvent evt) { // GEN-FIRST:event_searchActionPerformed interfaz.seleccionarFila(txtBuscar, tblRegistros); } // GEN-LAST:event_searchActionPerformed
private void formWindowClosing( java.awt.event.WindowEvent evt) // GEN-FIRST:event_formWindowClosing { // GEN-HEADEREND:event_formWindowClosing interfaz.menu(); } // GEN-LAST:event_formWindowClosing
private void chActivarActionPerformed( java.awt.event.ActionEvent evt) // GEN-FIRST:event_chActivarActionPerformed { // GEN-HEADEREND:event_chActivarActionPerformed interfaz.activarDesactivar(tblRegistros, chActivar); } // GEN-LAST:event_chActivarActionPerformed
private void btnModificarActionPerformed( java.awt.event.ActionEvent evt) // GEN-FIRST:event_btnModificarActionPerformed { // GEN-HEADEREND:event_btnModificarActionPerformed interfaz.modificar(tblRegistros); } // GEN-LAST:event_btnModificarActionPerformed
private void btnMenuActionPerformed( java.awt.event.ActionEvent evt) { // GEN-FIRST:event_btnMenuActionPerformed interfaz.menu(); } // GEN-LAST:event_btnMenuActionPerformed
private void btnInsertarActionPerformed( java.awt.event.ActionEvent evt) { // GEN-FIRST:event_btnInsertarActionPerformed interfaz.insertar(); } // GEN-LAST:event_btnInsertarActionPerformed