Implemented the GUI to open for the Flight Data Summary page however was unable to get it to open in the same stage so it opens in a new window. This is something to address later.

main
Liam Beckett 9 years ago
parent 9cc02bb305
commit 83ccf04d85

@ -5,10 +5,16 @@ import java.util.ResourceBundle;
import javax.swing.JOptionPane;
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.scene.Scene;
import javafx.scene.layout.BorderPane;
import javafx.stage.Stage;
import seng202.group9.Controller.App;
public class MenuController implements Initializable{
public void importAirports(){
JOptionPane.showMessageDialog(null, "This is not Implemented yet");
}
@ -25,6 +31,23 @@ public class MenuController implements Initializable{
JOptionPane.showMessageDialog(null, "This is not Implemented yet");
}
@FXML
public void viewFlightSummary() {
Stage stage = new Stage();
BorderPane root = new BorderPane(); //root panel
Scene scene = new Scene(root);
//create the Flight summary page
FlightDataSummary flightSummPage = new FlightDataSummary();
root.setTop(flightSummPage.getFlightSummary());
stage.setScene(scene);
stage.show();
//seng202.group9.Controller.App.primaryStage.setScene(scene);
//System.out.println("GOT HERE");
//seng202.group9.Controller.App.primaryStage.show();
}
public void initialize(URL arg0, ResourceBundle arg1) {
// TODO Auto-generated method stub

Loading…
Cancel
Save