Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.awt.EventQueue;
- import javax.swing.JFrame;
- import javax.swing.JPanel;
- import javax.swing.border.SoftBevelBorder;
- import javax.swing.border.BevelBorder;
- import javax.swing.JTextPane;
- import java.awt.Color;
- import javax.swing.JLabel;
- import java.awt.Font;
- import javax.swing.JTextField;
- import javax.swing.JProgressBar;
- import javax.swing.JButton;
- import javax.swing.AbstractAction;
- import java.awt.event.ActionEvent;
- import java.io.File;
- import javax.swing.Action;
- import javax.swing.JFileChooser;
- import java.awt.event.ActionListener;
- import javax.swing.JTable;
- import javax.swing.JScrollPane;
- public class GDI extends JFrame {
- /**
- *
- */
- private static final long serialVersionUID = 1L;
- private JPanel contentPane;
- private final Action botaoReber = new SwingAction();
- private final Action botaoEnviar = new SwingAction_1();
- JFileChooser chooser;
- private File file;
- private JFileChooser chooserDown;
- private JTable table;
- private JTextField codigoFilme;
- private JTextField tituloFilme;
- private JTextField anoFilme;
- private JTextField generoFilme;
- private JTextField codigoRoteiro;
- private JTextField classificacaoFilme;
- private JTextField notaFilme;
- private JTextField orcamentoFilme;
- /**
- * Launch the application.
- */
- public static void main(String[] args) {
- EventQueue.invokeLater(new Runnable() {
- public void run() {
- try {
- GDI frame = new GDI();
- frame.setVisible(true);
- } catch (Exception e) {
- e.printStackTrace();
- }
- }
- });
- }
- /**
- * Create the frame.
- */
- public GDI() {
- setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
- setBounds(100, 100, 1090, 606);
- contentPane = new JPanel();
- contentPane.setBackground(Color.LIGHT_GRAY);
- contentPane.setBorder(new SoftBevelBorder(BevelBorder.LOWERED, null, null, null, null));
- setContentPane(contentPane);
- contentPane.setLayout(null);
- table = new JTable();
- table.setBackground(Color.ORANGE);
- table.setBounds(599, 548, -533, -478);
- contentPane.add(table);
- codigoFilme = new JTextField();
- codigoFilme.setBounds(635, 121, 168, 20);
- contentPane.add(codigoFilme);
- codigoFilme.setColumns(10);
- JLabel lblCodigoDoFilme = new JLabel("Codigo do filme:");
- lblCodigoDoFilme.setBounds(635, 96, 89, 14);
- contentPane.add(lblCodigoDoFilme);
- JLabel lblTtuloDoFilme = new JLabel("T\u00EDtulo do filme:");
- lblTtuloDoFilme.setBounds(635, 152, 89, 14);
- contentPane.add(lblTtuloDoFilme);
- tituloFilme = new JTextField();
- tituloFilme.setColumns(10);
- tituloFilme.setBounds(635, 177, 168, 20);
- contentPane.add(tituloFilme);
- JLabel lblAnoDeProduo = new JLabel("Ano de produ\u00E7\u00E3o:");
- lblAnoDeProduo.setBounds(635, 208, 89, 14);
- contentPane.add(lblAnoDeProduo);
- anoFilme = new JTextField();
- anoFilme.setColumns(10);
- anoFilme.setBounds(635, 233, 168, 20);
- contentPane.add(anoFilme);
- JLabel lblGnero = new JLabel("G\u00EAnero:");
- lblGnero.setBounds(635, 264, 89, 14);
- contentPane.add(lblGnero);
- generoFilme = new JTextField();
- generoFilme.setColumns(10);
- generoFilme.setBounds(635, 289, 168, 20);
- contentPane.add(generoFilme);
- JLabel lblCdigoRoteiro = new JLabel("C\u00F3digo Roteiro");
- lblCdigoRoteiro.setBounds(841, 264, 89, 14);
- contentPane.add(lblCdigoRoteiro);
- codigoRoteiro = new JTextField();
- codigoRoteiro.setColumns(10);
- codigoRoteiro.setBounds(841, 289, 168, 20);
- contentPane.add(codigoRoteiro);
- JLabel lblClassificaoIndicativa = new JLabel("Classifica\u00E7\u00E3o indicativa:");
- lblClassificaoIndicativa.setBounds(841, 96, 134, 14);
- contentPane.add(lblClassificaoIndicativa);
- classificacaoFilme = new JTextField();
- classificacaoFilme.setColumns(10);
- classificacaoFilme.setBounds(841, 121, 168, 20);
- contentPane.add(classificacaoFilme);
- JLabel lblNotaCrtica = new JLabel("Nota Cr\u00EDtica:");
- lblNotaCrtica.setBounds(841, 152, 89, 14);
- contentPane.add(lblNotaCrtica);
- notaFilme = new JTextField();
- notaFilme.setColumns(10);
- notaFilme.setBounds(841, 177, 168, 20);
- contentPane.add(notaFilme);
- JLabel lblOramento = new JLabel("Or\u00E7amento:");
- lblOramento.setBounds(841, 208, 89, 14);
- contentPane.add(lblOramento);
- orcamentoFilme = new JTextField();
- orcamentoFilme.setColumns(10);
- orcamentoFilme.setBounds(841, 233, 168, 20);
- contentPane.add(orcamentoFilme);
- JButton btnInserir = new JButton("Inserir");
- btnInserir.setBounds(635, 347, 374, 54);
- contentPane.add(btnInserir);
- JLabel lblFilmeGdi = new JLabel("Filme GDI:");
- lblFilmeGdi.setBounds(20, 11, 78, 14);
- contentPane.add(lblFilmeGdi);
- JLabel lblNewLabel = new JLabel("");
- lblNewLabel.setBounds(646, 430, 363, 127);
- contentPane.add(lblNewLabel);
- }
- private class SwingAction extends AbstractAction {
- /**
- *
- */
- private static final long serialVersionUID = 1L;
- public SwingAction() {
- putValue(NAME, "Receber");
- putValue(SHORT_DESCRIPTION, "Some short description");
- }
- public void actionPerformed(ActionEvent e) {
- }
- }
- private class SwingAction_1 extends AbstractAction {
- /**
- *
- */
- private static final long serialVersionUID = 1L;
- public SwingAction_1() {
- putValue(NAME, "Enviar");
- putValue(SHORT_DESCRIPTION, "Some short description");
- }
- public void actionPerformed(ActionEvent e) {
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement