Views & Controller erstellt

This commit is contained in:
2023-01-17 15:58:22 +01:00
parent e245233a23
commit 3bb141fb52
17 changed files with 313 additions and 2 deletions

View File

@@ -0,0 +1,24 @@
package com.bib.essensbestellungsverwaltung;
import javafx.event.ActionEvent;
import javafx.fxml.FXMLLoader;
import javafx.scene.Node;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.stage.Stage;
import java.io.IOException;
public class SceneController {
private Stage stage;
private Scene scene;
private Parent root;
public void switchToLoginScene(ActionEvent event) throws IOException{
Parent root = FXMLLoader.load(getClass().getResource("login-view.fxml"));
stage = (Stage) ((Node)event.getSource()).getScene().getWindow();
scene = new Scene(root);
stage.setScene(scene);
stage.show();
}
}