add context menu to stations screen
This commit is contained in:
@@ -189,12 +189,18 @@ public class OffersController {
|
||||
|
||||
@FXML
|
||||
private void addStation() {
|
||||
Screeners.showAddStation(getSystem());
|
||||
SystemModel s = getSystem();
|
||||
if (!ModelFabric.isFake(s)){
|
||||
Screeners.showAddStation(s);
|
||||
}
|
||||
}
|
||||
|
||||
@FXML
|
||||
private void editStation() {
|
||||
Screeners.showEditStation(getStation());
|
||||
StationModel s = getStation();
|
||||
if (!ModelFabric.isFake(s)){
|
||||
Screeners.showEditStation(s);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -22,7 +22,16 @@
|
||||
<TextField fx:id="systemText" />
|
||||
</TitledPane>
|
||||
<TitledPane VBox.vgrow="ALWAYS" text="%market.stations" collapsible="false">
|
||||
<ListView fx:id="stationsList"/>
|
||||
<ListView fx:id="stationsList">
|
||||
<contextMenu>
|
||||
<ContextMenu>
|
||||
<items>
|
||||
<MenuItem text="%main.menu.edit.addStation" onAction="#addStation" />
|
||||
<MenuItem text="%main.menu.edit.editStation" onAction="#editStation" />
|
||||
</items>
|
||||
</ContextMenu>
|
||||
</contextMenu>
|
||||
</ListView>
|
||||
</TitledPane>
|
||||
</VBox>
|
||||
<TitledPane fx:id="stationPane" GridPane.columnIndex="1" maxHeight="60" collapsible="false">
|
||||
|
||||
Reference in New Issue
Block a user