slight improvement in car and loco manager
This commit is contained in:
2
pom.xml
2
pom.xml
@@ -4,7 +4,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>de.srsoftware</groupId>
|
<groupId>de.srsoftware</groupId>
|
||||||
<artifactId>web4rail</artifactId>
|
<artifactId>web4rail</artifactId>
|
||||||
<version>0.11.27</version>
|
<version>0.11.28</version>
|
||||||
<name>Web4Rail</name>
|
<name>Web4Rail</name>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<description>Java Model Railway Control</description>
|
<description>Java Model Railway Control</description>
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ FreeStartBlock : Start-Block freigeben
|
|||||||
Hardware settings : Hardware-Einstellungen
|
Hardware settings : Hardware-Einstellungen
|
||||||
Height : Höhe
|
Height : Höhe
|
||||||
Help : Hilfe
|
Help : Hilfe
|
||||||
|
(id: {}, length: {}) : (Id: {}, Länge: {})
|
||||||
if ({})\: : falls ({}):
|
if ({})\: : falls ({}):
|
||||||
inverted : invertiert
|
inverted : invertiert
|
||||||
learn : lernen
|
learn : lernen
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ public class Car extends BaseClass {
|
|||||||
private int id;
|
private int id;
|
||||||
private String name;
|
private String name;
|
||||||
public int length;
|
public int length;
|
||||||
private String stockId = "";
|
protected String stockId = "";
|
||||||
private Train train;
|
private Train train;
|
||||||
protected Plan plan;
|
protected Plan plan;
|
||||||
|
|
||||||
@@ -84,7 +84,9 @@ public class Car extends BaseClass {
|
|||||||
Tag list = new Tag("ul");
|
Tag list = new Tag("ul");
|
||||||
for (Car car : cars.values()) {
|
for (Car car : cars.values()) {
|
||||||
if (!(car instanceof Locomotive)) {
|
if (!(car instanceof Locomotive)) {
|
||||||
car.link("li").addTo(list);
|
Tag tag = car.link("li");
|
||||||
|
if (isSet(car.stockId) && !car.stockId.isEmpty()) tag.content(NBSP+t("(id: {}, length: {})",car.stockId,car.length));
|
||||||
|
tag.addTo(list);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
list.addTo(win);
|
list.addTo(win);
|
||||||
|
|||||||
@@ -204,7 +204,10 @@ public class Locomotive extends Car implements Constants,Device{
|
|||||||
for (Car car : cars.values()) {
|
for (Car car : cars.values()) {
|
||||||
if (car instanceof Locomotive) {
|
if (car instanceof Locomotive) {
|
||||||
Locomotive loco = (Locomotive) car;
|
Locomotive loco = (Locomotive) car;
|
||||||
loco.link("li").addTo(list);
|
Tag tag = loco.link("li");
|
||||||
|
if (isSet(loco.stockId) && !loco.stockId.isEmpty()) tag.content(NBSP+t("(id: {}, length: {})",loco.stockId,loco.length));
|
||||||
|
tag.addTo(list);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
list.addTo(win);
|
list.addTo(win);
|
||||||
|
|||||||
Reference in New Issue
Block a user