add current system button to offer and routeTrack screens
This commit is contained in:
@@ -190,6 +190,12 @@ public class OffersController {
|
|||||||
return station;
|
return station;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@FXML
|
||||||
|
private void currentSystem(){
|
||||||
|
ProfileModel profile = MainController.getProfile();
|
||||||
|
system.setValue(profile.getSystem());
|
||||||
|
}
|
||||||
|
|
||||||
@FXML
|
@FXML
|
||||||
private void addStation() {
|
private void addStation() {
|
||||||
SystemModel s = getSystem();
|
SystemModel s = getSystem();
|
||||||
|
|||||||
@@ -259,6 +259,13 @@ public class RouteTrackController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@FXML
|
||||||
|
private void newEntryAsCurrent(){
|
||||||
|
ProfileModel profile = MainController.getProfile();
|
||||||
|
newEntrySystem.setValue(profile.getSystem());
|
||||||
|
newEntryStation.setValue(profile.getStation().getName());
|
||||||
|
}
|
||||||
|
|
||||||
@FXML
|
@FXML
|
||||||
private void addEntry(){
|
private void addEntry(){
|
||||||
SystemModel toSystem = newEntrySystem.getValue();
|
SystemModel toSystem = newEntrySystem.getValue();
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
<?import javafx.scene.control.cell.*?>
|
<?import javafx.scene.control.cell.*?>
|
||||||
<?import javafx.scene.layout.*?>
|
<?import javafx.scene.layout.*?>
|
||||||
<?import ru.trader.view.support.cells.*?>
|
<?import ru.trader.view.support.cells.*?>
|
||||||
|
<?import org.controlsfx.glyphfont.Glyph?>
|
||||||
<GridPane xmlns="http://javafx.com/javafx/8" xmlns:fx="http://javafx.com/fxml/1"
|
<GridPane xmlns="http://javafx.com/javafx/8" xmlns:fx="http://javafx.com/fxml/1"
|
||||||
fx:controller="ru.trader.controllers.OffersController"
|
fx:controller="ru.trader.controllers.OffersController"
|
||||||
prefHeight="500">
|
prefHeight="500">
|
||||||
@@ -19,7 +20,7 @@
|
|||||||
|
|
||||||
<VBox GridPane.rowSpan="2" GridPane.vgrow="ALWAYS" minWidth="270">
|
<VBox GridPane.rowSpan="2" GridPane.vgrow="ALWAYS" minWidth="270">
|
||||||
<TitledPane text="%market.system.name" collapsible="false">
|
<TitledPane text="%market.system.name" collapsible="false">
|
||||||
<TextField fx:id="systemText" />
|
<HBox><TextField fx:id="systemText" HBox.hgrow="ALWAYS" /><Button minWidth="30" onAction="#currentSystem"><graphic><Glyph text="FontAwesome|MAP_MARKER"/></graphic></Button></HBox>
|
||||||
</TitledPane>
|
</TitledPane>
|
||||||
<TitledPane VBox.vgrow="ALWAYS" text="%market.stations" collapsible="false">
|
<TitledPane VBox.vgrow="ALWAYS" text="%market.stations" collapsible="false">
|
||||||
<ListView fx:id="stationsList">
|
<ListView fx:id="stationsList">
|
||||||
|
|||||||
@@ -51,7 +51,7 @@
|
|||||||
<Button prefWidth="30" onAction="#removeMission"><graphic><Glyph text="FontAwesome|MINUS"/></graphic></Button>
|
<Button prefWidth="30" onAction="#removeMission"><graphic><Glyph text="FontAwesome|MINUS"/></graphic></Button>
|
||||||
<Button prefWidth="30" onAction="#clearMissions"><graphic><Glyph text="FontAwesome|TRASH"/></graphic></Button>
|
<Button prefWidth="30" onAction="#clearMissions"><graphic><Glyph text="FontAwesome|TRASH"/></graphic></Button>
|
||||||
<VBox VBox.vgrow="ALWAYS" alignment="BOTTOM_LEFT">
|
<VBox VBox.vgrow="ALWAYS" alignment="BOTTOM_LEFT">
|
||||||
<Button prefWidth="30" onAction="#addAllMissionsToTrack"><graphic><Glyph text="FontAwesome|CHECK"/><Glyph text="FontAwesome|CHECK"/></graphic></Button>
|
<Button prefWidth="30" onAction="#addAllMissionsToTrack"><graphic><Glyph text="FontAwesome|CHECK"/></graphic></Button>
|
||||||
</VBox>
|
</VBox>
|
||||||
</VBox>
|
</VBox>
|
||||||
</HBox>
|
</HBox>
|
||||||
@@ -66,11 +66,11 @@
|
|||||||
<VBox>
|
<VBox>
|
||||||
<AnchorPane fx:id="track"/>
|
<AnchorPane fx:id="track"/>
|
||||||
<VBox>
|
<VBox>
|
||||||
<HBox><TextField fx:id="newEntrySystemText"/></HBox>
|
<HBox><TextField fx:id="newEntrySystemText"/><Button minWidth="30" onAction="#newEntryAsCurrent"><graphic><Glyph text="FontAwesome|MAP_MARKER"/></graphic></Button></HBox>
|
||||||
<HBox><ComboBox fx:id="newEntryStation"/></HBox>
|
<HBox><ComboBox fx:id="newEntryStation"/></HBox>
|
||||||
<HBox>
|
<HBox>
|
||||||
<Button onAction="#addEntry"><graphic><Glyph text="FontAwesome|PLUS"/></graphic></Button>
|
<Button onAction="#addEntry"><graphic><Glyph text="FontAwesome|PLUS"/></graphic></Button>
|
||||||
<Button onAction="#setActive"><graphic><Glyph text="FontAwesome|MAP_MARKER"/></graphic></Button>
|
<Button onAction="#setActive"><graphic><Glyph text="FontAwesome|CHECK"/></graphic></Button>
|
||||||
<Button onAction="#clear"><graphic><Glyph text="FontAwesome|TRASH"/></graphic></Button>
|
<Button onAction="#clear"><graphic><Glyph text="FontAwesome|TRASH"/></graphic></Button>
|
||||||
<Button onAction="#copyToClipboard"><graphic><Glyph text="FontAwesome|COPY"/></graphic></Button>
|
<Button onAction="#copyToClipboard"><graphic><Glyph text="FontAwesome|COPY"/></graphic></Button>
|
||||||
</HBox>
|
</HBox>
|
||||||
|
|||||||
Reference in New Issue
Block a user