ADD::Added checkstyle comments
FIX::fixed some checkstyle warnings
This commit is contained in:
@@ -48,10 +48,10 @@ public class DashBoardController {
|
||||
public void displayDashboard(ActionEvent event) {
|
||||
System.out.println("display dashboard");
|
||||
|
||||
// UserService service = new UserService();
|
||||
// UserDTO user = service.getName(null);
|
||||
// String name = user.getName();
|
||||
// welcomebacktext.setText("Welcome back, " + name);
|
||||
// UserService service = new UserService();
|
||||
// UserDTO user = service.getName(null);
|
||||
// String name = user.getName();
|
||||
// welcomebacktext.setText("Welcome back, " + name);
|
||||
|
||||
dashboardPane.setVisible(true);
|
||||
userPane.setVisible(false);
|
||||
|
||||
@@ -33,7 +33,7 @@ public class RegisterWindowController {
|
||||
*/
|
||||
@FXML
|
||||
public void handleSignUpButton(ActionEvent event) {
|
||||
//set the window to the current window (for displaying the alerts)
|
||||
//set the window to the current window (for displaying the alerts)
|
||||
Window owner = signupButton.getScene().getWindow();
|
||||
//check if the username field is empty
|
||||
if (userNameText.getText().isEmpty()) {
|
||||
|
||||
@@ -68,7 +68,9 @@ public class UserController {
|
||||
this.getClass().getClassLoader().getResource("fxml/dashboard.fxml")
|
||||
);
|
||||
Scene scene = new Scene(dash);
|
||||
scene.getStylesheets().add(getClass().getClassLoader().getResource("stylesheets/dashboardStyle.css").toExternalForm());
|
||||
scene.getStylesheets().add(getClass()
|
||||
.getClassLoader()
|
||||
.getResource("stylesheets/dashboardStyle.css").toExternalForm());
|
||||
Stage appStage = new Stage();
|
||||
appStage.setScene(scene);
|
||||
appStage.show();
|
||||
@@ -95,9 +97,15 @@ public class UserController {
|
||||
}
|
||||
}
|
||||
|
||||
public void handleRegisterButtonAction(ActionEvent event) throws Exception{
|
||||
/**
|
||||
* handles the click of the 'sign up' button.
|
||||
* opens a new stage where the user can register.
|
||||
* @param event the click of the button
|
||||
* @throws Exception an exception if the fxml file is not found
|
||||
*/
|
||||
public void handleRegisterButtonAction(ActionEvent event) throws Exception {
|
||||
//load the fxml file
|
||||
Parent registerWindow = FXMLLoader.load (
|
||||
Parent registerWindow = FXMLLoader.load(
|
||||
this.getClass().getClassLoader().getResource("fxml/RegisterWindow.fxml")
|
||||
);
|
||||
//make the window use the scene
|
||||
|
||||
Reference in New Issue
Block a user