2020-04-20 13:46:18 +02:00
|
|
|
package ihm;
|
|
|
|
|
|
|
|
import javafx.scene.Scene;
|
|
|
|
import javafx.scene.layout.Pane;
|
|
|
|
import javafx.stage.Modality;
|
|
|
|
import javafx.stage.Stage;
|
|
|
|
|
|
|
|
public class PopUp {
|
|
|
|
private Scene scene;
|
|
|
|
private Stage popupwindow;
|
2020-04-21 15:23:24 +02:00
|
|
|
private Pane pane;
|
2020-04-20 13:46:18 +02:00
|
|
|
|
|
|
|
public PopUp (Pane p, String titre) {
|
2020-04-21 15:23:24 +02:00
|
|
|
|
2020-04-20 13:46:18 +02:00
|
|
|
popupwindow = new Stage();
|
|
|
|
popupwindow.initModality(Modality.APPLICATION_MODAL);
|
|
|
|
popupwindow.setTitle(titre);
|
|
|
|
|
|
|
|
scene = new Scene(p);
|
|
|
|
}
|
|
|
|
|
|
|
|
public void display() {
|
|
|
|
popupwindow.setScene(scene);
|
|
|
|
popupwindow.showAndWait();
|
|
|
|
}
|
|
|
|
}
|