
net.rgielen.fxweaver.samples.springboot.controller.AnotherDialog Maven / Gradle / Ivy
The newest version!
package net.rgielen.fxweaver.samples.springboot.controller;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.Scene;
import javafx.scene.layout.VBox;
import javafx.stage.Stage;
import org.springframework.stereotype.Component;
/**
* @author Rene Gielen
*/
@Component
public class AnotherDialog {
@FXML
VBox dialog;
private Stage stage;
@FXML
public void initialize() {
this.stage = new Stage();
stage.setTitle("Another Dialog");
stage.setScene(new Scene(dialog));
}
public void show() {
stage.show();
}
@FXML
void click(ActionEvent actionEvent) {
stage.close();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy