Skip to content
Snippets Groups Projects
Commit 075c1100 authored by Vegard Johansen's avatar Vegard Johansen
Browse files

Empty application shell.

parent 687db48f
No related branches found
No related tags found
No related merge requests found
Pipeline #166275 failed
Showing
with 155 additions and 0 deletions
idatg1002_2022_group6.iml
.idea
README.md
\ No newline at end of file
pom.xml 0 → 100644
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>no.ntnu.idatg1002</groupId>
<artifactId>idatg1002_2022_group6</artifactId>
<version>1.0-SNAPSHOT</version>
<name>idatg1002_2022_group6</name>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<junit.version>5.7.1</junit.version>
</properties>
<dependencies>
<dependency>
<groupId>org.openjfx</groupId>
<artifactId>javafx-controls</artifactId>
<version>17-ea+11</version>
</dependency>
<dependency>
<groupId>org.openjfx</groupId>
<artifactId>javafx-fxml</artifactId>
<version>17-ea+11</version>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<configuration>
<source>17</source>
<target>17</target>
</configuration>
</plugin>
<plugin>
<groupId>org.openjfx</groupId>
<artifactId>javafx-maven-plugin</artifactId>
<version>0.0.6</version>
<executions>
<execution>
<!-- Default configuration for running with: mvn clean javafx:run -->
<id>default-cli</id>
<configuration>
<mainClass>
no.ntnu.idatg1002.idatg1002_2022_group6/no.ntnu.idatg1002.idatg1002_2022_group6.TableTennisApplication
</mainClass>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
\ No newline at end of file
module no.ntnu.idatg1002.idatg1002_2022_group6 {
requires javafx.controls;
requires javafx.fxml;
opens no.ntnu.idatg1002.idatg1002_2022_group6 to javafx.fxml;
exports no.ntnu.idatg1002.idatg1002_2022_group6;
}
\ No newline at end of file
package no.ntnu.idatg1002.idatg1002_2022_group6;
import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.stage.Stage;
import java.io.IOException;
public class TableTennisApplication extends Application {
@Override
public void start(Stage stage) throws IOException {
FXMLLoader fxmlLoader = new FXMLLoader(TableTennisApplication.class.getResource("table-tennis-view.fxml"));
Scene scene = new Scene(fxmlLoader.load(), 320, 240);
stage.setTitle("Table Tennis");
stage.setScene(scene);
stage.show();
}
public static void main(String[] args) {
launch();
}
}
\ No newline at end of file
package no.ntnu.idatg1002.idatg1002_2022_group6;
import javafx.fxml.FXML;
import javafx.scene.control.Label;
public class TableTennisController {
@FXML
private Label welcomeText;
@FXML
protected void onHelloButtonClick() {
welcomeText.setText("Welcome to our Table Tennis application!");
}
}
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.control.Button?>
<VBox alignment="CENTER" spacing="20.0" xmlns:fx="http://javafx.com/fxml"
fx:controller="no.ntnu.idatg1002.idatg1002_2022_group6.TableTennisController">
<padding>
<Insets bottom="20.0" left="20.0" right="20.0" top="20.0"/>
</padding>
<Label fx:id="welcomeText"/>
<Button text="Hello!" onAction="#onHelloButtonClick"/>
</VBox>
File added
File added
File added
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.control.Button?>
<VBox alignment="CENTER" spacing="20.0" xmlns:fx="http://javafx.com/fxml"
fx:controller="no.ntnu.idatg1002.idatg1002_2022_group6.TableTennisController">
<padding>
<Insets bottom="20.0" left="20.0" right="20.0" top="20.0"/>
</padding>
<Label fx:id="welcomeText"/>
<Button text="Hello!" onAction="#onHelloButtonClick"/>
</VBox>
C:\Users\Vegard\Desktop\NTNU 1. år BIDATA\2. semester\IDATG1002 - Syst.u\idatg1002_2022_group6\src\main\java\module-info.java
C:\Users\Vegard\Desktop\NTNU 1. år BIDATA\2. semester\IDATG1002 - Syst.u\idatg1002_2022_group6\src\main\java\no\ntnu\idatg1002\idatg1002_2022_group6\TableTennisController.java
C:\Users\Vegard\Desktop\NTNU 1. år BIDATA\2. semester\IDATG1002 - Syst.u\idatg1002_2022_group6\src\main\java\no\ntnu\idatg1002\idatg1002_2022_group6\TableTennisApplication.java
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment