use of com.exalttech.trex.ui.controllers.MainViewController in project trex-stateless-gui by cisco-system-traffic-generator.
the class TrexApp method start.
@Override
public void start(Stage stage) throws Exception {
speedupTooltip();
primaryStage = stage;
FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/MainView.fxml"));
AnchorPane page = fxmlLoader.load();
MainViewController mainviewcontroller = fxmlLoader.getController();
Scene scene = new Scene(page);
scene.getStylesheets().add(TrexApp.class.getResource("/styles/mainStyle.css").toExternalForm());
stage.setScene(scene);
stage.setTitle("TRex");
stage.setResizable(true);
stage.setMinWidth(780);
stage.setMinHeight(700);
stage.getIcons().add(new Image("/icons/trex.png"));
packetBuilderAppController = injector.getInstance(AppController.class);
PreferencesManager.getInstance().setPacketEditorConfigurations(packetBuilderAppController.getConfigurations());
packetBuilderAppController.registerEventBusHandler(mainviewcontroller);
stage.show();
}
Aggregations