Skip to content
Snippets Groups Projects
Commit d7870eca authored by Uli Bähr's avatar Uli Bähr
Browse files

Klassenvariablen eingeführt, MenuButton Variablen umbenannt

parent 064060e0
No related branches found
No related tags found
No related merge requests found
...@@ -25,6 +25,12 @@ ...@@ -25,6 +25,12 @@
<artifactId>javafx-fxml</artifactId> <artifactId>javafx-fxml</artifactId>
<version>${use.javafx.version}</version> <version>${use.javafx.version}</version>
</dependency> </dependency>
<!-- https://mvnrepository.com/artifact/net.sourceforge.plantuml/plantuml -->
<dependency>
<groupId>net.sourceforge.plantuml</groupId>
<artifactId>plantuml</artifactId>
<version>8059</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.xerial/sqlite-jdbc --> <!-- https://mvnrepository.com/artifact/org.xerial/sqlite-jdbc -->
<dependency> <dependency>
<groupId>org.xerial</groupId> <groupId>org.xerial</groupId>
......
...@@ -259,10 +259,12 @@ public class GuiController2 { ...@@ -259,10 +259,12 @@ public class GuiController2 {
assert mBtnStartPos2 != null : "fx:id=\"a3\" was not injected: check your FXML file 'gui.fxml'."; assert mBtnStartPos2 != null : "fx:id=\"a3\" was not injected: check your FXML file 'gui.fxml'.";
assert mBtnStartPos3 != null : "fx:id=\"a2\" was not injected: check your FXML file 'gui.fxml'."; assert mBtnStartPos3 != null : "fx:id=\"a2\" was not injected: check your FXML file 'gui.fxml'.";
assert mBtnNotchPos1 != null : "fx:id=\"r1\" was not injected: check your FXML file 'gui.fxml'."; assert mBtnNotchPos1 != null : "fx:id=\"r1\" was not injected: check your FXML file 'gui.fxml'.";
} }
/** /**
* Setzt die Anzeige des entsprechende Gui-Element auf die entsprechende Walze * Setzt die Anzeige des entsprechende Gui-Element auf die entsprechende Walze
* ->d.h. welche Walze sitzt auf welcher Position
* *
* @param walze => gibt die Walzennummer an (entspricht * @param walze => gibt die Walzennummer an (entspricht
* @param position => gibt die Position der Walze (entspricht * @param position => gibt die Position der Walze (entspricht
...@@ -270,14 +272,70 @@ public class GuiController2 { ...@@ -270,14 +272,70 @@ public class GuiController2 {
public void setzeWalze(int walze, int position){ public void setzeWalze(int walze, int position){
switch (position){ switch (position){
case 1: case 1:
mBtnWalzPos1.setText(); mBtnWalzPos1.setText(str[position]);
break; break;
case 2: case 2:
mBtnWalzPos2.setText(str[position]);
break; break;
case 3: case 3:
mBtnWalzPos3.setText(str[position]);
break;
default:
break; break;
} }
}
/**
* Setzt den Notch (position)=> die Mitnahmeposition der Walze (walze) fest
* Mitnahmeposition meint => die nächste Walze wird bei erreichen dieser Position (notch)
* um eine Stelle versetzt
*
* @param walze => gibt die walze an
* @param position => gibt den notch der Walze (walze) an
*/
public void setzeRing(int walze, int position){
switch (walze){
case 1:
mBtnNotchPos1.setText(num[position]);
break;
case 2:
mBtnNotchPos2.setText(num[position]);
break;
case 3:
mBtnNotchPos3.setText(num[position]);
break;
default:
break;
}
}
/**
* Setzt die Startposition/ aktuelle Position der Walze
* @param walze => gibt die walze an
* @param buchstabe gibt den Startwert bzw die aktuelle Position der Walze (walze) an
*/
public void setzePosition(int walze, char buchstabe){
switch (walze){
case 1:
mBtnStartPos1.setText(String.valueOf(buchstabe));
break;
case 2:
mBtnStartPos2.setText(buchstabe+"");
break;
case 3:
mBtnStartPos3.setText(buchstabe+"");
break;
default:
break;
}
} }
/**
* Setzt den aktuellen TagesSchluessel
* @param tagesSchluessel
*/
public void setzeTagesSchluessel(String tagesSchluessel){
}
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment