Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class GUI_ATR extends JFrame implements ActionListener{
- // einzelne Buttons setzen
- // 'static' da in Inhalt_ATR auch benutzt wird
- public static JButton kontaktlos_pruefen = new JButton();
- public static JButton manuelle_eingabe = new JButton();
- public void actionPerformed(ActionEvent e) {
- open_terminal();
- inhalt_auslesen.init_log_command_list();
- // hier mein 1. Button
- if (e.getSource() == this.kontaktlos_pruefen) {
- gui_leeren();
- if (Connect_Terminal.isTerminal_present() == true) {
- open_card();
- if (Connect_Card.isCard_present() == true) {
- textArea.append(Connect_Card.getCard().toString() + "\n");
- Ats_kontaktlos_OK.ausgabe();
- } else {
- kontaktlosFunktion.setVisible(true);
- }
- } else {
- textArea.setText("leser ist nicht eingesteckt");
- }
- }
- //hier mein 2. Button
- if (e.getSource() == this.manuelle_eingabe) {
- gui_leeren();
- open_terminal();
- if (Connect_Terminal.isTerminal_present() == true) {
- open_card();
- if (Connect_Card.isCard_present() == true) {
- Atr_anbieten_manuell.ausgabe();
- } else {
- lblBitteManuelleEingabe.setVisible(true);
- }
- } else {
- GUI_ATR.textArea.append("leser ist nicht eingesteckt\n");
- }
- }
- // Kontaktlos prΓΌfen Button
- panel.add(kontaktlos_pruefen);
- kontaktlos_pruefen.setSize(85, 35);
- kontaktlos_pruefen.setLocation(80, 5);
- kontaktlos_pruefen.setText("<html>Kontaktlos<br>pr\u00FCfen</html>");
- kontaktlos_pruefen.setVisible(false);
- // Manuelle Eingabe Button
- panel.add(manuelle_eingabe);
- manuelle_eingabe.setSize(85, 35);
- manuelle_eingabe.setLocation(260, 5);
- manuelle_eingabe.setText("<html>Manuelle<br>Eingabe</html>");
- addWindowListener(new meinWindowListener());
- kontaktlos_pruefen.addActionListener(this);
- manuelle_eingabe.addActionListener(this);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement