Compare commits
7 Commits
8f3042c5f9
...
23be5a1b91
Author | SHA1 | Date | |
---|---|---|---|
23be5a1b91 | |||
2944c44d1d | |||
e51ef5c49d | |||
bab5ef0a93 | |||
0303fcf467 | |||
d09d2baf42 | |||
adae09a1e9 |
@ -29,13 +29,13 @@ val jar by tasks.getting(Jar::class) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.register("blabla", Copy::class) {
|
tasks.register("rebuild and move", Copy::class) {
|
||||||
group = "dasdas"
|
group = "custom"
|
||||||
dependsOn("clean")
|
dependsOn("clean")
|
||||||
dependsOn("jar")
|
dependsOn("jar")
|
||||||
|
|
||||||
from("$buildDir/libs/app.jar")
|
from("$buildDir/libs/app.jar")
|
||||||
|
|
||||||
mkdir("$buildDir/newShit/")
|
mkdir("$buildDir/out/")
|
||||||
into("$buildDir/newShit/")
|
into("$buildDir/out/")
|
||||||
}
|
}
|
||||||
|
6
hellofx/app/build/resources/main/client/style.css
Normal file
6
hellofx/app/build/resources/main/client/style.css
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
|
||||||
|
.main-btn{
|
||||||
|
-fx-background-color: #424242;
|
||||||
|
-fx-text-fill: white;
|
||||||
|
-fx-border-radius: 50em;
|
||||||
|
}
|
@ -4,15 +4,16 @@ import javafx.application.Application;
|
|||||||
import javafx.fxml.FXMLLoader;
|
import javafx.fxml.FXMLLoader;
|
||||||
import javafx.scene.Scene;
|
import javafx.scene.Scene;
|
||||||
import javafx.stage.Stage;
|
import javafx.stage.Stage;
|
||||||
import res.RestController;
|
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.util.Objects;
|
||||||
|
|
||||||
public class MainApplication extends Application {
|
public class MainApplication extends Application {
|
||||||
@Override
|
@Override
|
||||||
public void start(Stage stage) throws IOException {
|
public void start(Stage stage) throws IOException {
|
||||||
FXMLLoader fxmlLoader = new FXMLLoader(MainApplication.class.getResource("main-view.fxml"));
|
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.setTitle("Hello!");
|
||||||
stage.setScene(scene);
|
stage.setScene(scene);
|
||||||
stage.show();
|
stage.show();
|
||||||
|
@ -6,7 +6,7 @@ import javafx.scene.layout.GridPane;
|
|||||||
import javafx.scene.layout.VBox;
|
import javafx.scene.layout.VBox;
|
||||||
import javafx.scene.paint.Color;
|
import javafx.scene.paint.Color;
|
||||||
import res.Event;
|
import res.Event;
|
||||||
import res.RestController;
|
import res.DataController;
|
||||||
|
|
||||||
public class MainController {
|
public class MainController {
|
||||||
@FXML
|
@FXML
|
||||||
@ -30,8 +30,8 @@ public class MainController {
|
|||||||
|
|
||||||
@FXML
|
@FXML
|
||||||
protected void onAddBtnClick(){
|
protected void onAddBtnClick(){
|
||||||
RestController restController = new RestController();
|
DataController dataController = new DataController();
|
||||||
Event[] eventList = restController.getAllEvents();
|
Event[] eventList = dataController.getAllEvents();
|
||||||
|
|
||||||
for(Event event : eventList){
|
for(Event event : eventList){
|
||||||
Label label = new Label();
|
Label label = new Label();
|
||||||
|
@ -6,103 +6,94 @@
|
|||||||
<?import javafx.scene.image.*?>
|
<?import javafx.scene.image.*?>
|
||||||
<?import javafx.scene.layout.*?>
|
<?import javafx.scene.layout.*?>
|
||||||
|
|
||||||
<GridPane gridLinesVisible="true" style="-fx-background-color: #424242;"
|
<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">
|
||||||
xmlns="http://javafx.com/javafx/11.0.2" xmlns:fx="http://javafx.com/fxml/1"
|
|
||||||
fx:controller="client.MainController">
|
|
||||||
<columnConstraints>
|
<columnConstraints>
|
||||||
<ColumnConstraints hgrow="NEVER" maxWidth="60.0" minWidth="60.0"/>
|
<ColumnConstraints hgrow="NEVER" maxWidth="60.0" minWidth="60.0" />
|
||||||
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0"/>
|
<ColumnConstraints hgrow="ALWAYS" />
|
||||||
</columnConstraints>
|
</columnConstraints>
|
||||||
<rowConstraints>
|
<rowConstraints>
|
||||||
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES"/>
|
<RowConstraints vgrow="SOMETIMES" />
|
||||||
</rowConstraints>
|
</rowConstraints>
|
||||||
<VBox alignment="TOP_CENTER" prefHeight="200.0" prefWidth="100.0" spacing="5.0"
|
<VBox alignment="TOP_CENTER" prefHeight="200.0" prefWidth="100.0" spacing="5.0" style="-fx-background-color: #333333;">
|
||||||
style="-fx-background-color: #333333;">
|
|
||||||
<ImageView fitHeight="50.0" fitWidth="50.0" pickOnBounds="true" preserveRatio="true">
|
<ImageView fitHeight="50.0" fitWidth="50.0" pickOnBounds="true" preserveRatio="true">
|
||||||
</ImageView>
|
</ImageView>
|
||||||
<Button mnemonicParsing="false" onAction="#onAddBtnClick" prefHeight="50" prefWidth="50"
|
<Button mnemonicParsing="false" onAction="#onAddBtnClick" prefHeight="50" prefWidth="50" styleClass="main-btn" text="ADD">
|
||||||
style="-fx-background-color: #424242;" text="ADD" textAlignment="CENTER" textFill="WHITE">
|
|
||||||
<cursor>
|
|
||||||
<Cursor fx:constant="HAND"/>
|
|
||||||
</cursor>
|
|
||||||
</Button>
|
</Button>
|
||||||
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;"
|
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;" textAlignment="CENTER" textFill="WHITE">
|
||||||
textAlignment="CENTER" textFill="WHITE">
|
|
||||||
ADD
|
ADD
|
||||||
<cursor>
|
<cursor>
|
||||||
<Cursor fx:constant="HAND"/>
|
<Cursor fx:constant="HAND" />
|
||||||
</cursor>
|
</cursor>
|
||||||
</Button>
|
</Button>
|
||||||
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;"
|
<Button mnemonicParsing="false" prefHeight="50" prefWidth="50" style="-fx-background-color: #424242;" textAlignment="CENTER" textFill="WHITE">
|
||||||
textAlignment="CENTER" textFill="WHITE">
|
|
||||||
ADD
|
ADD
|
||||||
<cursor>
|
<cursor>
|
||||||
<Cursor fx:constant="HAND"/>
|
<Cursor fx:constant="HAND" />
|
||||||
</cursor>
|
</cursor>
|
||||||
</Button>
|
</Button>
|
||||||
</VBox>
|
</VBox>
|
||||||
<GridPane fx:id="calendarGrid" gridLinesVisible="true" GridPane.columnIndex="1">
|
<GridPane fx:id="calendarGrid" gridLinesVisible="true" GridPane.columnIndex="1">
|
||||||
<columnConstraints>
|
<columnConstraints>
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857"/>
|
<ColumnConstraints hgrow="ALWAYS" percentWidth="14.2857142857" />
|
||||||
</columnConstraints>
|
</columnConstraints>
|
||||||
<rowConstraints>
|
<rowConstraints>
|
||||||
<RowConstraints maxHeight="25.0" minHeight="25.0" vgrow="NEVER"/>
|
<RowConstraints maxHeight="25.0" minHeight="25.0" vgrow="NEVER" />
|
||||||
<RowConstraints maxHeight="25.0" minHeight="25.0" vgrow="NEVER"/>
|
<RowConstraints maxHeight="25.0" minHeight="25.0" vgrow="NEVER" />
|
||||||
<RowConstraints vgrow="ALWAYS"/>
|
<RowConstraints vgrow="ALWAYS" />
|
||||||
</rowConstraints>
|
</rowConstraints>
|
||||||
<Label textFill="WHITE">
|
<Label textFill="WHITE">
|
||||||
Monat
|
Monat
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
|
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="0" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="0" GridPane.rowIndex="1">
|
||||||
Mo
|
Mo
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="1" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="1" GridPane.rowIndex="1">
|
||||||
Di
|
Di
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="2" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="2" GridPane.rowIndex="1">
|
||||||
Mi
|
Mi
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="3" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="3" GridPane.rowIndex="1">
|
||||||
Do
|
Do
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="4" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="4" GridPane.rowIndex="1">
|
||||||
Fr
|
Fr
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="5" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="5" GridPane.rowIndex="1">
|
||||||
Sa
|
Sa
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
<Label textFill="WHITE" GridPane.columnIndex="6" GridPane.rowIndex="1">
|
<Label textFill="WHITE" GridPane.columnIndex="6" GridPane.rowIndex="1">
|
||||||
So
|
So
|
||||||
<padding>
|
<padding>
|
||||||
<Insets left="5"/>
|
<Insets left="5" />
|
||||||
</padding>
|
</padding>
|
||||||
</Label>
|
</Label>
|
||||||
|
|
||||||
|
6
hellofx/app/src/main/resources/client/style.css
Normal file
6
hellofx/app/src/main/resources/client/style.css
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
|
||||||
|
.main-btn{
|
||||||
|
-fx-background-color: #424242;
|
||||||
|
-fx-text-fill: white;
|
||||||
|
-fx-border-radius: 50em;
|
||||||
|
}
|
@ -9,7 +9,7 @@ import java.net.HttpURLConnection;
|
|||||||
import java.net.URL;
|
import java.net.URL;
|
||||||
import java.util.ArrayList;
|
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_EVENTS_ENDPOINT = "http://localhost:8080/vpr/all-events";
|
||||||
private static final String ALL_USERS_ENDPOINT = "http://localhost:8080/vpr/all-users";
|
private static final String ALL_USERS_ENDPOINT = "http://localhost:8080/vpr/all-users";
|
Loading…
Reference in New Issue
Block a user