Classe Principal
public class Principal {
public static void main(String[] args) {
SegundaGui gui = new SegundaGui ();
gui.abrir();
}
}
Segunda Gui
import java.awt.Color;
import java.awt.Rectangle;
import java.awt.event.ActionListener;
import javax.swing.*;
public class SegundaGui extends JFrame {
public void abrir (){
JPanel painel = new JPanel();
this.getContentPane().setLayout(null);
this.setSize(500,500);
this.setTitle(“Minha SegundaGui”);
//Label Nome
JLabel label = new JLabel(“Nome”);
label.setBounds(new Rectangle(10,17,250,25));
painel.add(label);
//Campo de texto
final JTextField texto = new JTextField(10);
texto.setBackground(Color.white);
texto.setBounds(new Rectangle(10,17,150,150));
painel.add(texto);
//Botão Enviar
JButton botao = new [...]
