new player part 2

* homeflix now saves the progress you made for all films
* added icons for the player
* added a slider to set the play time for the player
* disable contols and cursor if mous is not moved for 5sec, enable it if moved
* autoplay, WIP needs testing
This commit is contained in:
Jannik
2018-04-02 02:18:43 +02:00
parent 2881c1f9d6
commit a918b0b1d8
11 changed files with 259 additions and 30 deletions

View File

@ -1,9 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import com.jfoenix.controls.JFXButton?>
<?import com.jfoenix.controls.JFXSlider?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.HBox?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.media.MediaView?>
<AnchorPane prefHeight="720.0" prefWidth="1280.0" style="-fx-background-color: black;" xmlns="http://javafx.com/javafx/9" xmlns:fx="http://javafx.com/fxml/1" fx:controller="kellerkinder.HomeFlix.player.PlayerController">
@ -13,14 +15,24 @@
<MediaView fx:id="mediaView" />
</children>
</HBox>
<HBox fx:id="controllsHBox" alignment="CENTER" spacing="10.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0">
<VBox fx:id="bottomVBox" alignment="CENTER" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0">
<children>
<JFXButton fx:id="playBtn" onAction="#playBtnAction" prefHeight="39.0" prefWidth="75.0" style="-fx-background-color: white;" text="play" />
<JFXButton fx:id="fullscreenBtn" onAction="#fullscreenBtnAction" prefHeight="39.0" style="-fx-background-color: white;" text="fullscreen" />
<JFXSlider fx:id="timeSlider">
<padding>
<Insets left="5.0" right="5.0" />
</padding>
</JFXSlider>
<HBox fx:id="controlsHBox" alignment="CENTER" spacing="10.0">
<children>
<JFXButton fx:id="stopBtn" buttonType="RAISED" onAction="#stopBtnAction" prefHeight="39.0" style="-fx-background-color: white;" />
<JFXButton fx:id="playBtn" buttonType="RAISED" onAction="#playBtnAction" prefHeight="39.0" style="-fx-background-color: white;" />
<JFXButton fx:id="fullscreenBtn" buttonType="RAISED" onAction="#fullscreenBtnAction" prefHeight="39.0" style="-fx-background-color: white;" />
</children>
<padding>
<Insets bottom="5.0" top="5.0" />
</padding>
</HBox>
</children>
<padding>
<Insets bottom="5.0" top="5.0" />
</padding>
</HBox>
</VBox>
</children>
</AnchorPane>

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 93 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 150 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 B