1
0

remove test button and fix play to give an actual user to LevelDesignWindow

This commit is contained in:
2021-06-15 21:42:32 +02:00
parent 2187337f86
commit b44c3ed39d
2 changed files with 7 additions and 16 deletions
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<form xmlns="http://www.intellij.com/uidesigner/form/" version="1" bind-to-class="de.oszimt.ls.aliendefence.view.menue.MainMenu">
<grid id="27dc6" binding="main" layout-manager="GridLayoutManager" row-count="14" column-count="3" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<grid id="27dc6" binding="main" layout-manager="GridLayoutManager" row-count="13" column-count="3" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<margin top="0" left="0" bottom="0" right="0"/>
<constraints>
<xy x="20" y="20" width="326" height="715"/>
@@ -75,14 +75,6 @@
<text value="Spielen"/>
</properties>
</component>
<component id="6cda2" class="javax.swing.JButton" binding="testButton">
<constraints>
<grid row="10" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties>
<text value="Testen"/>
</properties>
</component>
<component id="9d215" class="javax.swing.JTextField" binding="loginTextField">
<constraints>
<grid row="5" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="8" fill="1" indent="0" use-parent-layout="false">
@@ -93,7 +85,7 @@
</component>
<component id="7ae73" class="javax.swing.JButton" binding="levelEditorButton" default-binding="true">
<constraints>
<grid row="11" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
<grid row="10" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties>
<background color="-256"/>
@@ -103,7 +95,7 @@
</component>
<component id="ef1af" class="javax.swing.JButton" binding="exitButton">
<constraints>
<grid row="12" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
<grid row="11" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties>
<background color="-3552823"/>
@@ -128,7 +120,7 @@
</vspacer>
<vspacer id="8c4ad">
<constraints>
<grid row="13" column="1" row-span="1" col-span="1" vsize-policy="6" hsize-policy="1" anchor="0" fill="2" indent="0" use-parent-layout="false"/>
<grid row="12" column="1" row-span="1" col-span="1" vsize-policy="6" hsize-policy="1" anchor="0" fill="2" indent="0" use-parent-layout="false"/>
</constraints>
</vspacer>
<vspacer id="109a4">
@@ -16,7 +16,6 @@ public class MainMenu {
private JPanel main;
private JTextField loginTextField;
private JButton playButton;
private JButton testButton;
private JButton levelEditorButton;
private JButton exitButton;
private JPasswordField passwordTextField;
@@ -40,7 +39,7 @@ public class MainMenu {
Thread t = new Thread("GameThread") {
@Override
public void run() {
new LeveldesignWindow(alienDefenceController, user, LeveldesignWindow.TESTEN);
//GameController gameController = alienDefenceController.startGame(arrLevel.get(level.getSelectedIndex()), user);
//new GameGUI(gameController).start();
}
@@ -55,14 +54,14 @@ public class MainMenu {
});
// Button Testen - ActionListener
testButton.addActionListener(new ActionListener() {
/*testButton.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
// Erstellt Modell von aktuellen Nutzer
User user = new User(1, "test", "pass");
new LeveldesignWindow(alienDefenceController, user, LeveldesignWindow.TESTEN);
}
});
});*/
// Button Leveleditor
levelEditorButton.addActionListener(new ActionListener() {