Compare commits

..

3 Commits

Author SHA1 Message Date
2944c44d1d Merge remote-tracking branch 'origin/0100-Termine_anzeigen' into 0100-Termine_anzeigen
# Conflicts:
#	hellofx/app/build/resources/main/client/main-view.fxml
2021-11-15 13:22:52 +01:00
e51ef5c49d added css 2021-11-15 13:21:46 +01:00
bab5ef0a93 added css 2021-11-15 13:17:43 +01:00
7 changed files with 51 additions and 47 deletions

View File

@ -29,13 +29,13 @@ val jar by tasks.getting(Jar::class) {
})
}
tasks.register("blabla", Copy::class) {
group = "dasdas"
tasks.register("rebuild and move", Copy::class) {
group = "custom"
dependsOn("clean")
dependsOn("jar")
from("$buildDir/libs/app.jar")
mkdir("$buildDir/newShit/")
into("$buildDir/newShit/")
mkdir("$buildDir/out/")
into("$buildDir/out/")
}

View File

@ -0,0 +1,6 @@
.main-btn{
-fx-background-color: #424242;
-fx-text-fill: white;
-fx-border-radius: 50em;
}

View File

@ -4,15 +4,16 @@ import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.stage.Stage;
import res.RestController;
import java.io.IOException;
import java.util.Objects;
public class MainApplication extends Application {
@Override
public void start(Stage stage) throws IOException {
FXMLLoader fxmlLoader = new FXMLLoader(MainApplication.class.getResource("main-view.fxml"));
Scene scene = new Scene(fxmlLoader.load(), 1200, 800);
Scene scene = new Scene(fxmlLoader.load(), 1200, 700);
scene.getStylesheets().add(Objects.requireNonNull(MainApplication.class.getResource("style.css")).toExternalForm());
stage.setTitle("Hello!");
stage.setScene(scene);
stage.show();

View File

@ -6,7 +6,7 @@ import javafx.scene.layout.GridPane;
import javafx.scene.layout.VBox;
import javafx.scene.paint.Color;
import res.Event;
import res.RestController;
import res.DataController;
public class MainController {
@FXML
@ -30,8 +30,8 @@ public class MainController {
@FXML
protected void onAddBtnClick(){
RestController restController = new RestController();
Event[] eventList = restController.getAllEvents();
DataController dataController = new DataController();
Event[] eventList = dataController.getAllEvents();
for(Event event : eventList){
Label label = new Label();

View File

@ -6,35 +6,26 @@
<?import javafx.scene.image.*?>
<?import javafx.scene.layout.*?>
<GridPane gridLinesVisible="true" style="-fx-background-color: #424242;"
xmlns="http://javafx.com/javafx/11.0.2" xmlns:fx="http://javafx.com/fxml/1"
fx:controller="client.MainController">
<GridPane gridLinesVisible="true" style="-fx-background-color: #424242;" xmlns="http://javafx.com/javafx/11.0.2" xmlns:fx="http://javafx.com/fxml/1" fx:controller="client.MainController">
<columnConstraints>
<ColumnConstraints hgrow="NEVER" maxWidth="60.0" minWidth="60.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0"/>
<ColumnConstraints hgrow="ALWAYS" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES"/>
<RowConstraints vgrow="SOMETIMES" />
</rowConstraints>
<VBox alignment="TOP_CENTER" prefHeight="200.0" prefWidth="100.0" spacing="5.0"
style="-fx-background-color: #333333;">
<VBox alignment="TOP_CENTER" prefHeight="200.0" prefWidth="100.0" spacing="5.0" style="-fx-background-color: #333333;">
<ImageView fitHeight="50.0" fitWidth="50.0" pickOnBounds="true" preserveRatio="true">
</ImageView>
<Button mnemonicParsing="false" onAction="#onAddBtnClick" prefHeight="50" prefWidth="50"
style="-fx-background-color: #424242;" text="ADD" textAlignment="CENTER" textFill="WHITE">
<cursor>
<Cursor fx:constant="HAND"/>
</cursor>
<Button mnemonicParsing="false" onAction="#onAddBtnClick" prefHeight="50" prefWidth="50" styleClass="main-btn" text="ADD">
</Button>
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;"
textAlignment="CENTER" textFill="WHITE">
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;" textAlignment="CENTER" textFill="WHITE">
ADD
<cursor>
<Cursor fx:constant="HAND" />
</cursor>
</Button>
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;"
textAlignment="CENTER" textFill="WHITE">
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;" textAlignment="CENTER" textFill="WHITE">
ADD
<cursor>
<Cursor fx:constant="HAND" />

View File

@ -0,0 +1,6 @@
.main-btn{
-fx-background-color: #424242;
-fx-text-fill: white;
-fx-border-radius: 50em;
}

View File

@ -9,7 +9,7 @@ import java.net.HttpURLConnection;
import java.net.URL;
import java.util.ArrayList;
public class RestController {
public class DataController {
private static final String ALL_EVENTS_ENDPOINT = "http://localhost:8080/vpr/all-events";
private static final String ALL_USERS_ENDPOINT = "http://localhost:8080/vpr/all-users";