kauron/estraba
Archived
1
0
Fork 0

fixed paths, fixed some FXML mistakes, added icons to Initialize (not yet working)

This commit is contained in:
Jesús Vélez Palacios 2016-05-17 20:08:07 +02:00
parent 16d2602efe
commit 6f79ff9e3b
19 changed files with 68 additions and 15 deletions

View file

@ -0,0 +1,13 @@
<component name="libraryTable">
<library name="Maven: org.vesalainen.gpx:GPX11:1.0.2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/vesalainen/gpx/GPX11/1.0.2/GPX11-1.0.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/vesalainen/gpx/GPX11/1.0.2/GPX11-1.0.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/vesalainen/gpx/GPX11/1.0.2/GPX11-1.0.2-sources.jar!/" />
</SOURCES>
</library>
</component>

View file

@ -50,7 +50,7 @@ public class App extends Application {
@Override
public void start(Stage stage) throws Exception {
FXMLLoader loader = new FXMLLoader(
App.class.getResource("fxml/App.fxml"), GENERAL_BUNDLE);
App.class.getResource("fxml/Dashboard.fxml"), GENERAL_BUNDLE);
Parent root = loader.load();
stage.getIcons().add(new Image(App.class.getResource("img/icon.png").toString()));
stage.setTitle("ESTRABA");

View file

@ -1,11 +1,17 @@
package es.kauron.estraba.controller;
import com.jfoenix.controls.JFXButton;
import com.jfoenix.controls.JFXListView;
import com.jfoenix.controls.JFXTabPane;
import com.lynden.gmapsfx.GoogleMapView;
import es.kauron.estraba.App;
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.scene.chart.AreaChart;
import javafx.scene.chart.LineChart;
import javafx.scene.control.Tab;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
import java.net.URL;
import java.util.ResourceBundle;
@ -17,6 +23,9 @@ import java.util.ResourceBundle;
public class DashboardController implements Initializable {
@FXML
private JFXTabPane root;
@FXML
private Tab tabDashboard;
@ -29,26 +38,42 @@ public class DashboardController implements Initializable {
@FXML
private JFXListView<?> mapSummary;
@FXML
private JFXButton elevationButton;
@FXML
private JFXButton speedButton;
@FXML
private JFXButton hrButton;
@FXML
private JFXButton cadenceButton;
@FXML
private Tab tabGraph;
@FXML
private AreaChart<?, ?> elevationChart;
private AreaChart<Double, Double> elevationChart;
@FXML
private LineChart<?, ?> speedChart;
private LineChart<Double, Double> speedChart;
@FXML
private LineChart<?, ?> hrChart;
private LineChart<Double, Double> hrChart;
@FXML
private LineChart<?, ?> cadenceChart;
private LineChart<Double, Double> cadenceChart;
@FXML
private Tab tabSettings;
@Override
public void initialize(URL location, ResourceBundle resources) {
elevationButton.setGraphic(new ImageView(new Image(App.class.getResourceAsStream("img/elevation.png"))));
speedButton.setGraphic(new ImageView(new Image(App.class.getResourceAsStream("img/speed.png"))));
hrButton.setGraphic(new ImageView(new Image(App.class.getResourceAsStream("img/hr.png"))));
cadenceButton.setGraphic(new ImageView(new Image(App.class.getResourceAsStream("img/cadence.png"))));
}
}

View file

@ -12,11 +12,11 @@
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.Tab?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.HBox?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?>
<?import jfxtras.scene.layout.HBox?>
<?import jfxtras.scene.layout.VBox?>
<JFXTabPane prefHeight="600.0" prefWidth="800.0" xmlns="http://javafx.com/javafx/8.0.76-ea" xmlns:fx="http://javafx.com/fxml/1">
<JFXTabPane fx:id="root" prefHeight="600.0" prefWidth="800.0" xmlns="http://javafx.com/javafx/8.0.76-ea" xmlns:fx="http://javafx.com/fxml/1">
<tabs>
<Tab fx:id="tabDashboard" text="%tab.dashboard">
<content>
@ -34,20 +34,20 @@
<content>
<VBox>
<children>
<HBox>
<HBox VBox.vgrow="ALWAYS">
<children>
<GoogleMapView fx:id="mapView" />
<GoogleMapView fx:id="mapView" HBox.hgrow="ALWAYS" />
<JFXListView fx:id="mapSummary" minWidth="100.0" />
</children>
</HBox>
<HBox minHeight="128.0" prefHeight="0.0">
<children>
<VBox prefHeight="200.0" prefWidth="100.0">
<VBox prefHeight="200.0" prefWidth="100.0" HBox.hgrow="ALWAYS">
<children>
<JFXButton minHeight="32.0" minWidth="32.0" />
<JFXButton layoutX="10.0" layoutY="10.0" minHeight="32.0" minWidth="32.0" />
<JFXButton layoutX="10.0" layoutY="10.0" minHeight="32.0" minWidth="32.0" />
<JFXButton layoutX="10.0" layoutY="42.0" minHeight="32.0" minWidth="32.0" />
<JFXButton fx:id="elevationButton" minHeight="32.0" minWidth="32.0" />
<JFXButton fx:id="speedButton" layoutX="10.0" layoutY="10.0" minHeight="32.0" minWidth="32.0" />
<JFXButton fx:id="hrButton" layoutX="10.0" layoutY="10.0" minHeight="32.0" minWidth="32.0" />
<JFXButton fx:id="cadenceButton" layoutX="10.0" layoutY="42.0" minHeight="32.0" minWidth="32.0" />
</children>
</VBox>
<LineChart minHeight="100.0" prefWidth="9999.0">

View file

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 3.3 KiB

View file

Before

Width:  |  Height:  |  Size: 922 B

After

Width:  |  Height:  |  Size: 922 B

View file

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View file

Before

Width:  |  Height:  |  Size: 822 B

After

Width:  |  Height:  |  Size: 822 B

View file

Before

Width:  |  Height:  |  Size: 857 B

After

Width:  |  Height:  |  Size: 857 B

View file

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View file

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View file

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

View file

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 3.3 KiB

View file

Before

Width:  |  Height:  |  Size: 3 KiB

After

Width:  |  Height:  |  Size: 3 KiB

View file

Before

Width:  |  Height:  |  Size: 3.5 KiB

After

Width:  |  Height:  |  Size: 3.5 KiB

View file

Before

Width:  |  Height:  |  Size: 3 KiB

After

Width:  |  Height:  |  Size: 3 KiB

View file

@ -0,0 +1,5 @@
label.welcome=Welcome!
tab.dashboard=Dashboard
tab.graph=Stats
tab.map=Your Route
tab.settings=Settings

View file

@ -0,0 +1,5 @@
label.welcome=¡Benvinguts!
tab.dashboard=Sumari
tab.graph=Estadístiques
tab.map=La teva ruta
tab.settings=Ajustos

View file

@ -0,0 +1,5 @@
label.welcome=¡Bienvenido!
tab.dashboard=Resúmen
tab.graph=Estadísticas
tab.map=Tu ruta
tab.settings=Ajustes