From fb7d543bf60c7746b067c9100666af245dbab967 Mon Sep 17 00:00:00 2001 From: Michael-Jouanneau Date: Sat, 29 Oct 2016 20:23:17 +0200 Subject: [PATCH] Removed no Fullscreen code --- src/sample/Main.java | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/sample/Main.java b/src/sample/Main.java index ddefa5d..d9f80d7 100644 --- a/src/sample/Main.java +++ b/src/sample/Main.java @@ -11,19 +11,13 @@ public class Main extends Application { @Override public void start(Stage primaryStage) throws Exception{ - primaryStage.initStyle(StageStyle.UNIFIED); + primaryStage.initStyle(StageStyle.UNDECORATED); Parent root = FXMLLoader.load(getClass().getResource("sample.fxml")); primaryStage.setTitle("Hello World"); primaryStage.setScene(new Scene(root, 900, 500)); primaryStage.show(); - primaryStage.maximizedProperty().addListener((observable, oldValue, newValue) -> { - if (newValue) - primaryStage.setMaximized(false); - }); - root.lookup("#exit").setOnMouseClicked(event -> primaryStage.close()); // Close program if button is clicked + root.lookup("#exit").setOnMouseClicked(event -> primaryStage.close()); } - - public static void main(String[] args) { launch(args); }