forked from Apple-2-Tools/jace
51 lines
1.3 KiB
Java
51 lines
1.3 KiB
Java
/*
|
|
* To change this license header, choose License Headers in Project Properties.
|
|
* To change this template file, choose Tools | Templates
|
|
* and open the template in the editor.
|
|
*/
|
|
|
|
package jace;
|
|
|
|
import java.io.IOException;
|
|
import javafx.application.Application;
|
|
import javafx.fxml.FXMLLoader;
|
|
import javafx.scene.Parent;
|
|
import javafx.scene.Scene;
|
|
import javafx.scene.layout.AnchorPane;
|
|
import javafx.stage.Stage;
|
|
|
|
/**
|
|
*
|
|
* @author blurry
|
|
*/
|
|
public class JaceApplication extends Application {
|
|
|
|
Stage primaryStage;
|
|
JaceUIController controller;
|
|
|
|
@Override
|
|
public void start(Stage stage) throws Exception {
|
|
primaryStage = stage;
|
|
FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/JaceUI.fxml"));
|
|
fxmlLoader.setResources(null);
|
|
try {
|
|
AnchorPane node = (AnchorPane) fxmlLoader.load();
|
|
controller = fxmlLoader.getController();
|
|
Scene s = new Scene(node);
|
|
primaryStage.setScene(s);
|
|
} catch (IOException exception) {
|
|
throw new RuntimeException(exception);
|
|
}
|
|
|
|
primaryStage.show();
|
|
}
|
|
|
|
/**
|
|
* @param args the command line arguments
|
|
*/
|
|
public static void main(String[] args) {
|
|
launch(args);
|
|
}
|
|
|
|
}
|