package visão;
public class TelaLogin extends javax.swing.JFrame {
/**
* Creates new form TelaLogin
*/
public TelaLogin() {
initComponents();
}
/**
* 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">
private void initComponents() {
jButton1Acessar = new javax.swing.JButton();
jButton1Sair = new javax.swing.JButton();
jLabel1Usuário = new javax.swing.JLabel();
jLabel2Senha = new javax.swing.JLabel();
jTextField1Usuário = new javax.swing.JTextField();
jPasswordField1Senha = new javax.swing.JPasswordField();
LabelFundoLogin = new javax.swing.JLabel();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
getContentPane().setLayout(null);
jButton1Acessar.setText("Acessar");
getContentPane().add(jButton1Acessar);
jButton1Acessar.setBounds(190, 110, 71, 23);
jButton1Sair.setText("Sair");
getContentPane().add(jButton1Sair);
jButton1Sair.setBounds(280, 110, 51, 23);
jLabel1Usuário.setText("Usuário:");
getContentPane().add(jLabel1Usuário);
jLabel1Usuário.setBounds(170, 50, 50, 20);
jLabel2Senha.setText("Senha:");
getContentPane().add(jLabel2Senha);
jLabel2Senha.setBounds(170, 80, 40, 20);
getContentPane().add(jTextField1Usuário);
jTextField1Usuário.setBounds(210, 50, 120, 20);
jPasswordField1Senha.setText("jPasswordField1");
getContentPane().add(jPasswordField1Senha);
jPasswordField1Senha.setBounds(210, 80, 120, 20);
LabelFundoLogin.setIcon(new javax.swing.ImageIcon(getClass().getResource("/imagens/fundotelaLogin.png"))); // NOI18N
getContentPane().add(LabelFundoLogin);
LabelFundoLogin.setBounds(20, 0, 489, 300);
setSize(new java.awt.Dimension(572, 339));
setLocationRelativeTo(null);
}// </editor-fold>
private void JButton
TelaPrincipal tela = new (TelaPrincipal);
Tela.setVisible(true);
dispose();
public static void main(String args[]) {
try {
for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
if ("Nimbus".equals(info.getName())) {
javax.swing.UIManager.setLookAndFeel(info.getClassName());
break;
}
}
} catch (ClassNotFoundException ex) {
java.util.logging.Logger.getLogger(TelaLogin.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
} catch (InstantiationException ex) {
java.util.logging.Logger.getLogger(TelaLogin.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
} catch (IllegalAccessException ex) {
java.util.logging.Logger.getLogger(TelaLogin.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
} catch (javax.swing.UnsupportedLookAndFeelException ex) {
java.util.logging.Logger.getLogger(TelaLogin.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
}
//</editor-fold>
/* Create and display the form */
java.awt.EventQueue.invokeLater(new Runnable() {
public void run() {
new TelaLogin().setVisible(true);
}
});
}
// Variables declaration - do not modify
private javax.swing.JLabel LabelFundoLogin;
private javax.swing.JButton jButton1Acessar;
private javax.swing.JButton jButton1Sair;
private javax.swing.JLabel jLabel1Usuário;
private javax.swing.JLabel jLabel2Senha;
private javax.swing.JPasswordField jPasswordField1Senha;
private javax.swing.JTextField jTextField1Usuário;
// End of variables declaration
}
