mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 06:18:44 +00:00
- Fixed JFXDialog initialised in lobby, raceview, serverlist controller by default. Now, dialog only appears when called.
- [WIP] Created keybindingdialog fxml. CSS not yet done. - Removed top most anchorpane on raceview so parent is stackpane like other views. #story[1278]
This commit is contained in:
@@ -90,16 +90,16 @@ public class LobbyController implements Initializable {
|
|||||||
ViewManager.getInstance().getPlayerList().setAll(ViewManager.getInstance().getPlayerList().sorted());
|
ViewManager.getInstance().getPlayerList().setAll(ViewManager.getInstance().getPlayerList().sorted());
|
||||||
});
|
});
|
||||||
|
|
||||||
|
customizeButton.setOnMouseReleased(event -> {
|
||||||
|
customizationDialog = createCustomizeDialog();
|
||||||
|
Sounds.playButtonClick();
|
||||||
|
customizationDialog.show();
|
||||||
|
});
|
||||||
|
|
||||||
Platform.runLater(() -> {
|
Platform.runLater(() -> {
|
||||||
Integer playerId = ViewManager.getInstance().getGameClient().getServerThread().getClientId();
|
Integer playerId = ViewManager.getInstance().getGameClient().getServerThread().getClientId();
|
||||||
|
|
||||||
playersColor = Colors.getColor(playerId - 1);
|
playersColor = Colors.getColor(playerId - 1);
|
||||||
customizationDialog = createCustomizeDialog();
|
|
||||||
|
|
||||||
customizeButton.setOnMouseReleased(event -> {
|
|
||||||
Sounds.playButtonClick();
|
|
||||||
customizationDialog.show();
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
|
|
||||||
leaveLobbyButton.setOnMouseEntered(e -> Sounds.playHoverSound());
|
leaveLobbyButton.setOnMouseEntered(e -> Sounds.playHoverSound());
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
|
|||||||
@FXML
|
@FXML
|
||||||
private Label timerLabel;
|
private Label timerLabel;
|
||||||
@FXML
|
@FXML
|
||||||
private StackPane contentAnchorPane;
|
private StackPane contentStackPane;
|
||||||
|
|
||||||
private GridPane contentGridPane;
|
private GridPane contentGridPane;
|
||||||
@FXML
|
@FXML
|
||||||
@@ -134,8 +134,6 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
|
|||||||
Sounds.stopMusic();
|
Sounds.stopMusic();
|
||||||
Sounds.playRaceMusic();
|
Sounds.playRaceMusic();
|
||||||
|
|
||||||
finishScreenDialog = createFinishDialog();
|
|
||||||
|
|
||||||
// Load a default important annotation state
|
// Load a default important annotation state
|
||||||
//importantAnnotations = new ImportantAnnotationsState();
|
//importantAnnotations = new ImportantAnnotationsState();
|
||||||
|
|
||||||
@@ -180,9 +178,10 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
|
|||||||
// chatHistory.textProperty().addListener((obs, oldValue, newValue) -> {
|
// chatHistory.textProperty().addListener((obs, oldValue, newValue) -> {
|
||||||
// chatHistory.setScrollTop(Double.MAX_VALUE);
|
// chatHistory.setScrollTop(Double.MAX_VALUE);
|
||||||
// });
|
// });
|
||||||
rvAnchorPane.setOnMouseClicked((event) ->
|
|
||||||
rvAnchorPane.requestFocus()
|
contentStackPane.setOnMouseClicked(event -> {
|
||||||
);
|
contentStackPane.requestFocus();
|
||||||
|
});
|
||||||
|
|
||||||
//Makes the chat history non transparent when clicked on
|
//Makes the chat history non transparent when clicked on
|
||||||
chatInput.focusedProperty().addListener(new ChangeListener<Boolean>() {
|
chatInput.focusedProperty().addListener(new ChangeListener<Boolean>() {
|
||||||
@@ -200,26 +199,27 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
|
|||||||
|
|
||||||
public void showFinishDialog(ArrayList<ClientYacht> finishedBoats) {
|
public void showFinishDialog(ArrayList<ClientYacht> finishedBoats) {
|
||||||
raceState.setRaceStarted(false);
|
raceState.setRaceStarted(false);
|
||||||
finishDialogController.setFinishedBoats(finishedBoats);
|
createFinishDialog(finishedBoats);
|
||||||
finishScreenDialog.show();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private JFXDialog createFinishDialog() {
|
/**
|
||||||
|
* Create finishScreenDialog and set up finishDialogController.
|
||||||
|
*/
|
||||||
|
private void createFinishDialog(ArrayList<ClientYacht> finishedBoats) {
|
||||||
FXMLLoader dialog = new FXMLLoader(
|
FXMLLoader dialog = new FXMLLoader(
|
||||||
getClass().getResource("/views/dialogs/RaceFinishDialog.fxml"));
|
getClass().getResource("/views/dialogs/RaceFinishDialog.fxml"));
|
||||||
|
|
||||||
JFXDialog finishScreenDialog = null;
|
Platform.runLater(() -> {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
finishScreenDialog = new JFXDialog(contentAnchorPane, dialog.load(),
|
finishScreenDialog = new JFXDialog(contentStackPane, dialog.load(),
|
||||||
JFXDialog.DialogTransition.CENTER);
|
JFXDialog.DialogTransition.CENTER);
|
||||||
|
finishDialogController = dialog.getController();
|
||||||
|
finishDialogController.setFinishedBoats(finishedBoats);
|
||||||
|
finishScreenDialog.show();
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
});
|
||||||
finishDialogController = dialog.getController();
|
|
||||||
|
|
||||||
return finishScreenDialog;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void loadRace (
|
public void loadRace (
|
||||||
@@ -245,7 +245,7 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
|
|||||||
gameView = new GameView3D();
|
gameView = new GameView3D();
|
||||||
// gameView.setFrameRateFXText(fpsDisplay);
|
// gameView.setFrameRateFXText(fpsDisplay);
|
||||||
Platform.runLater(() -> {
|
Platform.runLater(() -> {
|
||||||
contentAnchorPane.getChildren().add(0, gameView.getAssets());
|
contentStackPane.getChildren().add(0, gameView.getAssets());
|
||||||
((SubScene) gameView.getAssets()).widthProperty()
|
((SubScene) gameView.getAssets()).widthProperty()
|
||||||
.bind(ViewManager.getInstance().getStage().widthProperty());
|
.bind(ViewManager.getInstance().getStage().widthProperty());
|
||||||
((SubScene) gameView.getAssets()).heightProperty()
|
((SubScene) gameView.getAssets()).heightProperty()
|
||||||
@@ -805,7 +805,7 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
|
|||||||
public String readChatInput() {
|
public String readChatInput() {
|
||||||
String chat = chatInput.getText();
|
String chat = chatInput.getText();
|
||||||
chatInput.clear();
|
chatInput.clear();
|
||||||
rvAnchorPane.requestFocus();
|
contentStackPane.requestFocus();
|
||||||
return chat;
|
return chat;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -112,16 +112,23 @@ public class ServerListController implements Initializable, ServerListenerDelega
|
|||||||
serverListVBox.getChildren().add(noServersFound);
|
serverListVBox.getChildren().add(noServersFound);
|
||||||
|
|
||||||
// Set up dialog for server creation
|
// Set up dialog for server creation
|
||||||
|
serverListHostButton.setOnAction(action -> {
|
||||||
|
showServerCreationDialog();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Shows Server Creation Dialog when "Host" button is clicked.
|
||||||
|
*/
|
||||||
|
private void showServerCreationDialog() {
|
||||||
Platform.runLater(() -> {
|
Platform.runLater(() -> {
|
||||||
FXMLLoader dialogContent = new FXMLLoader(getClass().getResource(
|
FXMLLoader dialogContent = new FXMLLoader(getClass().getResource(
|
||||||
"/views/dialogs/ServerCreationDialog.fxml"));
|
"/views/dialogs/ServerCreationDialog.fxml"));
|
||||||
try {
|
try {
|
||||||
JFXDialog dialog = new JFXDialog(serverListMainStackPane, dialogContent.load(),
|
JFXDialog dialog = new JFXDialog(serverListMainStackPane, dialogContent.load(),
|
||||||
DialogTransition.CENTER);
|
DialogTransition.CENTER);
|
||||||
serverListHostButton.setOnAction(action -> {
|
|
||||||
dialog.show();
|
dialog.show();
|
||||||
Sounds.playButtonClick();
|
Sounds.playButtonClick();
|
||||||
});
|
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
logger.warn("Could not create Server Creation Dialog.");
|
logger.warn("Could not create Server Creation Dialog.");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,11 +2,17 @@ package seng302.visualiser.controllers;
|
|||||||
|
|
||||||
import com.jfoenix.controls.JFXButton;
|
import com.jfoenix.controls.JFXButton;
|
||||||
import com.jfoenix.controls.JFXDecorator;
|
import com.jfoenix.controls.JFXDecorator;
|
||||||
|
import com.jfoenix.controls.JFXDialog;
|
||||||
|
import com.jfoenix.controls.JFXDialog.DialogTransition;
|
||||||
|
import com.jfoenix.controls.events.JFXDialogEvent;
|
||||||
import com.jfoenix.svg.SVGGlyph;
|
import com.jfoenix.svg.SVGGlyph;
|
||||||
|
import com.sun.org.apache.xpath.internal.operations.Bool;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import javafx.application.Platform;
|
import javafx.application.Platform;
|
||||||
import javafx.collections.ObservableList;
|
import javafx.collections.ObservableList;
|
||||||
|
import javafx.event.ActionEvent;
|
||||||
|
import javafx.event.EventHandler;
|
||||||
import javafx.fxml.FXMLLoader;
|
import javafx.fxml.FXMLLoader;
|
||||||
import javafx.scene.Cursor;
|
import javafx.scene.Cursor;
|
||||||
import javafx.scene.Node;
|
import javafx.scene.Node;
|
||||||
@@ -14,7 +20,10 @@ import javafx.scene.Parent;
|
|||||||
import javafx.scene.Scene;
|
import javafx.scene.Scene;
|
||||||
import javafx.scene.SceneAntialiasing;
|
import javafx.scene.SceneAntialiasing;
|
||||||
import javafx.scene.image.Image;
|
import javafx.scene.image.Image;
|
||||||
|
import javafx.scene.input.MouseEvent;
|
||||||
import javafx.scene.layout.HBox;
|
import javafx.scene.layout.HBox;
|
||||||
|
import javafx.scene.layout.Pane;
|
||||||
|
import javafx.scene.layout.StackPane;
|
||||||
import javafx.scene.paint.Color;
|
import javafx.scene.paint.Color;
|
||||||
import javafx.stage.Stage;
|
import javafx.stage.Stage;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
@@ -32,11 +41,6 @@ public class ViewManager {
|
|||||||
private HashMap<String, String> properties; //TODO is this the best way to do this??
|
private HashMap<String, String> properties; //TODO is this the best way to do this??
|
||||||
private ObservableList<String> playerList;
|
private ObservableList<String> playerList;
|
||||||
private Logger logger = LoggerFactory.getLogger(ViewManager.class);
|
private Logger logger = LoggerFactory.getLogger(ViewManager.class);
|
||||||
|
|
||||||
public Stage getStage() {
|
|
||||||
return stage;
|
|
||||||
}
|
|
||||||
|
|
||||||
private Stage stage;
|
private Stage stage;
|
||||||
|
|
||||||
private ViewManager() {
|
private ViewManager() {
|
||||||
@@ -119,6 +123,23 @@ public class ViewManager {
|
|||||||
//Get the button box
|
//Get the button box
|
||||||
HBox btns = (HBox) decorator.getChildren().get(0);
|
HBox btns = (HBox) decorator.getChildren().get(0);
|
||||||
|
|
||||||
|
//Create settings button -- [WIP]
|
||||||
|
JFXButton btnSettings = new JFXButton();
|
||||||
|
btnSettings.setText(" Key Bindings");
|
||||||
|
btnSettings.setStyle("-fx-text-fill:#fff");
|
||||||
|
btnSettings.getStyleClass().add("jfx-decorator-button");
|
||||||
|
btnSettings.setCursor(Cursor.HAND);
|
||||||
|
|
||||||
|
btnSettings.setOnMouseClicked(event -> Platform.runLater(() -> {
|
||||||
|
try {
|
||||||
|
if (!checkDialogOpened(decorator.getChildren())) {
|
||||||
|
showKeyBindingDialog();
|
||||||
|
}
|
||||||
|
} catch (IOException e) {
|
||||||
|
logger.warn("Could not create Key Binding Dialog.");
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
|
||||||
//Create new button
|
//Create new button
|
||||||
JFXButton btnMute = new JFXButton();
|
JFXButton btnMute = new JFXButton();
|
||||||
btnMute.setText(" Toggle Sound");
|
btnMute.setText(" Toggle Sound");
|
||||||
@@ -134,9 +155,13 @@ public class ViewManager {
|
|||||||
SVGGlyph volumeOff = new SVGGlyph(0, "VOLUME_ON",
|
SVGGlyph volumeOff = new SVGGlyph(0, "VOLUME_ON",
|
||||||
"M13.5,9 C13.5,7.2 12.5,5.7 11,5 L11,7.2 L13.5,9.7 L13.5,9 L13.5,9 Z M16,9 C16,9.9 15.8,10.8 15.5,11.6 L17,13.1 C17.7,11.9 18,10.4 18,8.9 C18,4.6 15,1 11,0.1 L11,2.2 C13.9,3.2 16,5.8 16,9 L16,9 Z M1.3,0 L0,1.3 L4.7,6 L0,6 L0,12 L4,12 L9,17 L9,10.3 L13.3,14.6 C12.6,15.1 11.9,15.5 11,15.8 L11,17.9 C12.4,17.6 13.6,17 14.7,16.1 L16.7,18.1 L18,16.8 L9,7.8 L1.3,0 L1.3,0 Z M9,1 L6.9,3.1 L9,5.2 L9,1 L9,1 Z",
|
"M13.5,9 C13.5,7.2 12.5,5.7 11,5 L11,7.2 L13.5,9.7 L13.5,9 L13.5,9 Z M16,9 C16,9.9 15.8,10.8 15.5,11.6 L17,13.1 C17.7,11.9 18,10.4 18,8.9 C18,4.6 15,1 11,0.1 L11,2.2 C13.9,3.2 16,5.8 16,9 L16,9 Z M1.3,0 L0,1.3 L4.7,6 L0,6 L0,12 L4,12 L9,17 L9,10.3 L13.3,14.6 C12.6,15.1 11.9,15.5 11,15.8 L11,17.9 C12.4,17.6 13.6,17 14.7,16.1 L16.7,18.1 L18,16.8 L9,7.8 L1.3,0 L1.3,0 Z M9,1 L6.9,3.1 L9,5.2 L9,1 L9,1 Z",
|
||||||
Color.WHITE);
|
Color.WHITE);
|
||||||
|
SVGGlyph keyBindingGlyph = new SVGGlyph(0, "KEY_BINDING",
|
||||||
|
"M19.43 12.98c.04-.32.07-.64.07-.98s-.03-.66-.07-.98l2.11-1.65c.19-.15.24-.42.12-.64l-2-3.46c-.12-.22-.39-.3-.61-.22l-2.49 1c-.52-.4-1.08-.73-1.69-.98l-.38-2.65C14.46 2.18 14.25 2 14 2h-4c-.25 0-.46.18-.49.42l-.38 2.65c-.61.25-1.17.59-1.69.98l-2.49-1c-.23-.09-.49 0-.61.22l-2 3.46c-.13.22-.07.49.12.64l2.11 1.65c-.04.32-.07.65-.07.98s.03.66.07.98l-2.11 1.65c-.19.15-.24.42-.12.64l2 3.46c.12.22.39.3.61.22l2.49-1c.52.4 1.08.73 1.69.98l.38 2.65c.03.24.24.42.49.42h4c.25 0 .46-.18.49-.42l.38-2.65c.61-.25 1.17-.59 1.69-.98l2.49 1c.23.09.49 0 .61-.22l2-3.46c.12-.22.07-.49-.12-.64l-2.11-1.65zM12 15.5c-1.93 0-3.5-1.57-3.5-3.5s1.57-3.5 3.5-3.5 3.5 1.57 3.5 3.5-1.57 3.5-3.5 3.5z",
|
||||||
|
Color.WHITE);
|
||||||
volumeOn.setSize(16, 16);
|
volumeOn.setSize(16, 16);
|
||||||
volumeOff.setSize(16, 16);
|
volumeOff.setSize(16, 16);
|
||||||
spacer.setSize(40, 16);
|
spacer.setSize(40, 16);
|
||||||
|
keyBindingGlyph.setSize(16,16);
|
||||||
|
|
||||||
// Determine which graphic should go on the button
|
// Determine which graphic should go on the button
|
||||||
if (Sounds.isMusicMuted() && Sounds.isSoundEffectsMuted()) {
|
if (Sounds.isMusicMuted() && Sounds.isSoundEffectsMuted()) {
|
||||||
@@ -145,9 +170,12 @@ public class ViewManager {
|
|||||||
btnMute.setGraphic(volumeOn);
|
btnMute.setGraphic(volumeOn);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
btnSettings.setGraphic(keyBindingGlyph);
|
||||||
|
|
||||||
// Add Buttons
|
// Add Buttons
|
||||||
btns.getChildren().add(0, spacer);
|
btns.getChildren().add(0, spacer);
|
||||||
btns.getChildren().add(0, btnMute);
|
btns.getChildren().add(0, btnMute);
|
||||||
|
btns.getChildren().add(0, btnSettings);
|
||||||
btnMute.setOnAction((action) -> {
|
btnMute.setOnAction((action) -> {
|
||||||
Sounds.toggleAllSounds();
|
Sounds.toggleAllSounds();
|
||||||
if (btnMute.getGraphic().equals(volumeOff)) {
|
if (btnMute.getGraphic().equals(volumeOff)) {
|
||||||
@@ -159,6 +187,31 @@ public class ViewManager {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private Boolean checkDialogOpened(ObservableList<Node> nodes) {
|
||||||
|
for (Node node : nodes) {
|
||||||
|
if (node instanceof JFXDialog) {
|
||||||
|
return true;
|
||||||
|
} else if (node instanceof StackPane) {
|
||||||
|
return checkDialogOpened(((StackPane) node).getChildren());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void showKeyBindingDialog() throws IOException {
|
||||||
|
FXMLLoader dialogContent = new FXMLLoader(getClass().getResource(
|
||||||
|
"/views/dialogs/KeyBindingDialog.fxml"));
|
||||||
|
for (Node node : decorator.getChildren()) {
|
||||||
|
if (node instanceof StackPane) {
|
||||||
|
JFXDialog dialog = new JFXDialog((StackPane) node,
|
||||||
|
dialogContent.load(),
|
||||||
|
DialogTransition.CENTER);
|
||||||
|
dialog.show();
|
||||||
|
Sounds.playButtonClick();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determines if a PC has compatibility with the bonjour protocol for server detection.
|
* Determines if a PC has compatibility with the bonjour protocol for server detection.
|
||||||
*/
|
*/
|
||||||
@@ -221,6 +274,7 @@ public class ViewManager {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Change the view to the Lobby Screen
|
* Change the view to the Lobby Screen
|
||||||
|
*
|
||||||
* @param disableReadyButton Boolean value so that clients can't try start a game.
|
* @param disableReadyButton Boolean value so that clients can't try start a game.
|
||||||
* @return A LobbyController object for the Lobby Screen.
|
* @return A LobbyController object for the Lobby Screen.
|
||||||
*/
|
*/
|
||||||
@@ -243,6 +297,7 @@ public class ViewManager {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets up the view for the race. Creating a new decorator and destroying the old one.
|
* Sets up the view for the race. Creating a new decorator and destroying the old one.
|
||||||
|
*
|
||||||
* @return A RaceViewController for the race view screen.
|
* @return A RaceViewController for the race view screen.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -296,4 +351,8 @@ public class ViewManager {
|
|||||||
|
|
||||||
return loader.getController();
|
return loader.getController();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Stage getStage() {
|
||||||
|
return stage;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,13 +14,12 @@
|
|||||||
<?import javafx.scene.layout.RowConstraints?>
|
<?import javafx.scene.layout.RowConstraints?>
|
||||||
<?import javafx.scene.layout.StackPane?>
|
<?import javafx.scene.layout.StackPane?>
|
||||||
<?import javafx.scene.text.Font?>
|
<?import javafx.scene.text.Font?>
|
||||||
<AnchorPane fx:id="rvAnchorPane" maxHeight="1.7976931348623157E308"
|
<StackPane fx:id="contentStackPane" maxHeight="1.7976931348623157E308"
|
||||||
maxWidth="1.7976931348623157E308" minHeight="-Infinity" minWidth="-Infinity" prefHeight="800.0"
|
maxWidth="1.7976931348623157E308" minHeight="-Infinity" minWidth="-Infinity"
|
||||||
prefWidth="1200.0" style="-fx-background-color: skyblue;" xmlns="http://javafx.com/javafx/8"
|
prefHeight="800.0" prefWidth="1200.0"
|
||||||
|
style="-fx-background-color: skyblue;" xmlns="http://javafx.com/javafx/8"
|
||||||
xmlns:fx="http://javafx.com/fxml/1"
|
xmlns:fx="http://javafx.com/fxml/1"
|
||||||
fx:controller="seng302.visualiser.controllers.RaceViewController">
|
fx:controller="seng302.visualiser.controllers.RaceViewController">
|
||||||
<children>
|
|
||||||
<StackPane fx:id="contentAnchorPane" maxHeight="1.7976931348623157E308" maxWidth="1.7976931348623157E308" prefHeight="800.0" prefWidth="1200.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
|
|
||||||
<children>
|
<children>
|
||||||
<GridPane maxHeight="1.7976931348623157E308" maxWidth="1.7976931348623157E308"
|
<GridPane maxHeight="1.7976931348623157E308" maxWidth="1.7976931348623157E308"
|
||||||
prefHeight="800.0" prefWidth="1200.0">
|
prefHeight="800.0" prefWidth="1200.0">
|
||||||
@@ -161,7 +160,8 @@
|
|||||||
<columnConstraints>
|
<columnConstraints>
|
||||||
<ColumnConstraints hgrow="SOMETIMES" maxWidth="110.0"
|
<ColumnConstraints hgrow="SOMETIMES" maxWidth="110.0"
|
||||||
minWidth="110.0" prefWidth="110.0"/>
|
minWidth="110.0" prefWidth="110.0"/>
|
||||||
<ColumnConstraints hgrow="SOMETIMES" maxWidth="132.0" minWidth="10.0"
|
<ColumnConstraints hgrow="SOMETIMES" maxWidth="132.0"
|
||||||
|
minWidth="10.0"
|
||||||
prefWidth="132.0"/>
|
prefWidth="132.0"/>
|
||||||
</columnConstraints>
|
</columnConstraints>
|
||||||
<rowConstraints>
|
<rowConstraints>
|
||||||
@@ -238,10 +238,8 @@
|
|||||||
</children>
|
</children>
|
||||||
</GridPane>
|
</GridPane>
|
||||||
</children>
|
</children>
|
||||||
</StackPane>
|
|
||||||
</children>
|
|
||||||
<stylesheets>
|
<stylesheets>
|
||||||
<String fx:value="/css/Master.css"/>
|
<String fx:value="/css/Master.css"/>
|
||||||
<String fx:value="/css/RaceView.css"/>
|
<String fx:value="/css/RaceView.css"/>
|
||||||
</stylesheets>
|
</stylesheets>
|
||||||
</AnchorPane>
|
</StackPane>
|
||||||
|
|||||||
@@ -0,0 +1,50 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
|
||||||
|
<?import java.net.*?>
|
||||||
|
<?import javafx.scene.control.*?>
|
||||||
|
<?import javafx.scene.layout.*?>
|
||||||
|
<?import com.jfoenix.controls.*?>
|
||||||
|
<?import java.lang.*?>
|
||||||
|
|
||||||
|
<JFXDialogLayout maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="600.0" prefWidth="550.0" xmlns="http://javafx.com/javafx/8" xmlns:fx="http://javafx.com/fxml/1">
|
||||||
|
<children>
|
||||||
|
<GridPane>
|
||||||
|
<columnConstraints>
|
||||||
|
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
|
||||||
|
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
|
||||||
|
</columnConstraints>
|
||||||
|
<rowConstraints>
|
||||||
|
<RowConstraints maxHeight="90.0" minHeight="90.0" prefHeight="90.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
<RowConstraints maxHeight="60.0" minHeight="60.0" prefHeight="60.0" vgrow="SOMETIMES" />
|
||||||
|
</rowConstraints>
|
||||||
|
<children>
|
||||||
|
<Label text="Custom Keybind" GridPane.columnSpan="2" GridPane.halignment="CENTER" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="Zoom in" GridPane.halignment="CENTER" GridPane.rowIndex="1" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="Zoom out" GridPane.halignment="CENTER" GridPane.rowIndex="2" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="VMG" GridPane.halignment="CENTER" GridPane.rowIndex="3" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="Sails in/out" GridPane.halignment="CENTER" GridPane.rowIndex="4" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="Tack/Gybe" GridPane.halignment="CENTER" GridPane.rowIndex="5" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="Upwind" GridPane.halignment="CENTER" GridPane.rowIndex="6" GridPane.valignment="CENTER" />
|
||||||
|
<Label text="Downwind" GridPane.halignment="CENTER" GridPane.rowIndex="7" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="Z" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="1" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="X" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="2" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="SPACE" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="3" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="SHIFT" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="4" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="ENTER" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="5" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="PAGE_UP" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="6" GridPane.valignment="CENTER" />
|
||||||
|
<JFXButton buttonType="RAISED" text="PAGE_DOWN" GridPane.columnIndex="1" GridPane.halignment="CENTER" GridPane.rowIndex="7" GridPane.valignment="CENTER" />
|
||||||
|
</children>
|
||||||
|
</GridPane>
|
||||||
|
</children>
|
||||||
|
<stylesheets>
|
||||||
|
<URL value="@../../css/dialogs/KeyBindingDialog.css" />
|
||||||
|
<URL value="@../../css/Master.css" />
|
||||||
|
</stylesheets>
|
||||||
|
</JFXDialogLayout>
|
||||||
Reference in New Issue
Block a user