From a045b4779714eabfc1a9473c40c84d8eb3f3cf98 Mon Sep 17 00:00:00 2001
From: Andreas Weninger <e01526989@student.tuwien.ac.at>
Date: Mon, 11 Jun 2018 17:33:14 +0200
Subject: [#27381] CreateOperstionController changes to properly align the
 half-transparent pane & the registration-pane.
---
 .../controller/CreateOperationController.java        |  3 +++
 .../resources/fxml/CreateOperationController.fxml    | 20 ++++++++++++++------
 2 files changed, 17 insertions(+), 6 deletions(-)
diff --git a/src/main/java/at/ac/tuwien/sepm/assignment/groupphase/einsatzverwaltung/controller/CreateOperationController.java b/src/main/java/at/ac/tuwien/sepm/assignment/groupphase/einsatzverwaltung/controller/CreateOperationController.java
index 9648d8a..e791205 100644
--- a/src/main/java/at/ac/tuwien/sepm/assignment/groupphase/einsatzverwaltung/controller/CreateOperationController.java
+++ b/src/main/java/at/ac/tuwien/sepm/assignment/groupphase/einsatzverwaltung/controller/CreateOperationController.java
@@ -81,6 +81,7 @@ public class CreateOperationController {
 
     @FXML
     private void initialize() {
+
         lblChosenVehicles.setText("keine ausgewählt");
         lvActiveOperations.setCellFactory(
                 param ->
@@ -105,7 +106,9 @@ public class CreateOperationController {
                         openDetailsWindow(lvActiveOperations.getSelectionModel().getSelectedItem());
                     }
                 });
+
         createCarController.setVisible(false);
+        registrationWindowController.setVisible(false);
     }
 
     public void updateList() {
diff --git a/src/main/resources/fxml/CreateOperationController.fxml b/src/main/resources/fxml/CreateOperationController.fxml
index d22dc45..9a6462d 100644
--- a/src/main/resources/fxml/CreateOperationController.fxml
+++ b/src/main/resources/fxml/CreateOperationController.fxml
@@ -8,6 +8,7 @@
 <?import javafx.scene.layout.AnchorPane?>
 <?import javafx.scene.layout.FlowPane?>
 <?import javafx.scene.text.Font?>
+<?import javafx.scene.layout.GridPane?>
 <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity"
   prefHeight="650.0" prefWidth="1200.0" xmlns="http://javafx.com/javafx/9.0.1"
   xmlns:fx="http://javafx.com/fxml/1"
@@ -66,7 +67,7 @@
     styleClass="text-small"
     textFill="WHITE">
   </Hyperlink>
-  <AnchorPane fx:id="apActiveOperations" layoutX="968.0" layoutY="71.0" prefHeight="315.0"
+  <AnchorPane layoutX="968.0" layoutY="71.0" prefHeight="315.0"
     prefWidth="207.0"
     styleClass="bg-white, shadowed">
     <ListView fx:id="lvActiveOperations" layoutX="4.0" layoutY="74.0" prefHeight="242.0"
@@ -80,12 +81,19 @@
   <FlowPane fx:id="fpVehicles" hgap="12" layoutX="40.0" layoutY="228.0" prefHeight="388.0"
     prefWidth="920.0" vgap="12">
   </FlowPane>
-  <AnchorPane fx:id="apInvisible" prefHeight="650.0" prefWidth="1200.0"
+  <AnchorPane fx:id="apInvisible" AnchorPane.topAnchor="0" AnchorPane.leftAnchor="0"
+    AnchorPane.rightAnchor="0" AnchorPane.bottomAnchor="0"
     style="-fx-background-color: rgba(0,0,0,0.7);" visible="false"/>
   <fx:include fx:id="operationDetails" source="/fxml/OperationDetails.fxml"
     AnchorPane.leftAnchor="54.0" AnchorPane.topAnchor="50.0"/>
-  <fx:include AnchorPane.leftAnchor="192.0" AnchorPane.topAnchor="57.0" fx:id="manageEmployees" source="/fxml/manageEmployees.fxml"/>
-  <fx:include AnchorPane.leftAnchor="300" AnchorPane.topAnchor="135.4" source="/fxml/RegistrationWindow.fxml" fx:id="registrationWindow"/>
-  <fx:include AnchorPane.leftAnchor="300.0" AnchorPane.topAnchor="125.0" source="/fxml/createCar.fxml" fx:id="createCar"/>
-  <fx:include AnchorPane.leftAnchor="100.0" source="/fxml/ArchiveOperation.fxml" fx:id="archiveOperation"/>
+  <fx:include AnchorPane.leftAnchor="192.0" AnchorPane.topAnchor="57.0" fx:id="manageEmployees"
+    source="/fxml/manageEmployees.fxml"/>
+  <GridPane AnchorPane.topAnchor="0" AnchorPane.leftAnchor="0"
+    AnchorPane.rightAnchor="0" AnchorPane.bottomAnchor="0" alignment="CENTER">
+    <fx:include source="/fxml/RegistrationWindow.fxml" fx:id="registrationWindow"/>
+  </GridPane>
+  <fx:include AnchorPane.leftAnchor="300.0" AnchorPane.topAnchor="125.0"
+    source="/fxml/createCar.fxml" fx:id="createCar"/>
+  <fx:include AnchorPane.leftAnchor="100.0" source="/fxml/ArchiveOperation.fxml"
+    fx:id="archiveOperation"/>
 </AnchorPane>
-- 
cgit v1.2.3-70-g09d2