diff --git a/src/de/jaujau/gui/texturenauswaehlen_GUI.java b/src/de/jaujau/gui/texturenauswaehlen_GUI.java index 05ce0e4..fd8e24a 100644 --- a/src/de/jaujau/gui/texturenauswaehlen_GUI.java +++ b/src/de/jaujau/gui/texturenauswaehlen_GUI.java @@ -1,9 +1,13 @@ package de.jaujau.gui; import java.awt.BorderLayout; +import java.awt.Font; +import javax.swing.JButton; import javax.swing.JFrame; +import javax.swing.JLabel; import javax.swing.JPanel; +import javax.swing.SwingConstants; import javax.swing.border.EmptyBorder; import de.jaujau.daten.Texturenpakete; @@ -17,6 +21,8 @@ public class texturenauswaehlen_GUI extends JFrame{ private JPanel contentPane; private Texturenpakete pakete; + private JButton ok, hinzufuegen, entfernen; + public texturenauswaehlen_GUI (Texturenpakete texturenpakete) { pakete = texturenpakete; erstelleFenster(); @@ -24,12 +30,41 @@ public class texturenauswaehlen_GUI extends JFrame{ } private void erstelleFenster() { + //Fenster größen fetslegen setAlwaysOnTop(true); setBounds(100, 100, 588, 382); contentPane = new JPanel(); contentPane.setBorder(new EmptyBorder(5, 5, 5, 5)); contentPane.setLayout(new BorderLayout(0, 0)); setContentPane(contentPane); + + //Text "Texturenauswahl" + JLabel lblNewLabel = new JLabel("Texturenauswahl"); + lblNewLabel.setFont(new Font("Tahoma", Font.PLAIN, 20)); + lblNewLabel.setHorizontalAlignment(SwingConstants.CENTER); + contentPane.add(lblNewLabel, BorderLayout.NORTH); + + //Teste Hinzufügen + hinzufuegen = new JButton("Hinzufügen"); + hinzufuegen.setBounds(20, 20, 225, 20); + hinzufuegen.addActionListener(e-> paketHinzufuegeb()); + contentPane.add(hinzufuegen); + + //Teste Entfernen + entfernen = new JButton("Entfernen"); + entfernen.setBounds(30, 30, 225, 20); + entfernen.addActionListener(e-> paketHinzufuegeb()); + contentPane.add(entfernen); + + //Teste OK + ok = new JButton("OK"); + ok.setBounds(40, 40, 225, 20); + ok.addActionListener(e-> paketHinzufuegeb()); + contentPane.add(ok); + } + + private void paketHinzufuegeb() { + }