Skip to content

Commit

Permalink
finish implementing login, and fill a few information in the main window
Browse files Browse the repository at this point in the history
you can also log off, then on another account
some optimisations
renamed data controllers to data managers

Still some cleanup to do
  • Loading branch information
Ljaysoft committed Aug 14, 2016
1 parent a31ed3d commit e955b40
Show file tree
Hide file tree
Showing 13 changed files with 473 additions and 347 deletions.
38 changes: 24 additions & 14 deletions src/main/resources/layout/MainWindow.fxml
Expand Up @@ -4,7 +4,7 @@
<?import javafx.scene.image.ImageView?>
<?import javafx.scene.layout.*?>
<?import javafx.scene.text.Font?>
<VBox prefHeight="487.0" prefWidth="599.0" xmlns="http://javafx.com/javafx/8.0.60" xmlns:fx="http://javafx.com/fxml/1" >
<VBox xmlns:fx="http://javafx.com/fxml/1" prefHeight="487.0" prefWidth="599.0" xmlns="http://javafx.com/javafx/8.0.60">
<children>
<MenuBar prefHeight="25.0" prefWidth="634.0" VBox.vgrow="NEVER">
<menus>
Expand All @@ -27,26 +27,36 @@
<children>
<HBox fx:id="PlayerInfo">
<children>
<ImageView fx:id="teamIcon" fitHeight="32.0" fitWidth="32.0" pickOnBounds="true" preserveRatio="true"/>
<Label fx:id="playerNameLabel" prefHeight="17.0" prefWidth="70.0" text="PlayerName">
<ImageView fx:id="teamIcon" fitHeight="32.0" fitWidth="32.0" pickOnBounds="true"
preserveRatio="true"/>
<Separator maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity"
orientation="VERTICAL"/>
<Label fx:id="playerNameLabel" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity"
minWidth="-Infinity" text="PlayerName">
<font>
<Font name="System Bold" size="12.0"/>
</font>
</Label>
<Label text=" Lvl: "/>
<Label fx:id="playerLvl" prefHeight="17.0" prefWidth="32.0" text="PH_"/>
<Label fx:id="playerStardustLbl" prefHeight="17.0" prefWidth="99.0" text=" ###########">
<Separator maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity"
orientation="VERTICAL"/>
<Label fx:id="playerLvl" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity"
minWidth="-Infinity" text="playerLvl"/>
<Separator maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity"
orientation="VERTICAL"/>
<Label fx:id="playerStardustLbl" maxHeight="-Infinity" maxWidth="-Infinity"
minHeight="-Infinity" minWidth="-Infinity" text=" ########### Stardust">
<font>
<Font name="System Bold" size="12.0"/>
</font>
</Label>
<Label text="Stardust"/>
<Separator orientation="VERTICAL" prefHeight="17.0" prefWidth="18.0"/>
<Label fx:id="nbPkmInBagsLbl" text="###/### "/>
<Label text="Pokémon"/>
<Separator orientation="VERTICAL" prefHeight="17.0" prefWidth="18.0"/>
<Label fx:id="nbItemsBagsLbl" text="###/### "/>
<Label text="Items"/>
<Separator maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity"
orientation="VERTICAL"/>
<Label fx:id="nbPkmInBagsLbl" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity"
minWidth="-Infinity" text="###/### Pokémon"/>
<Separator maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity"
orientation="VERTICAL"/>
<Label fx:id="nbItemsBagsLbl" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity"
minWidth="-Infinity" text="###/### Items"/>
</children>
</HBox>
</children>
Expand All @@ -57,7 +67,7 @@
<tabs>
<Tab text="LuckyEggGrinder">
<content>
<Button fx:id="openGrinderBtn" prefHeight="25.0" prefWidth="105.0" text="Open"/>
<Button fx:id="openGrinderBtn" prefHeight="25.0" prefWidth="105.0" text="Open"/>
<!-- problem with the embeding atm -->
<!--fx:include fx:id="grinderPane" source="LuckyEggGrinder.fxml" />-->
</content>
Expand Down
23 changes: 11 additions & 12 deletions src/me/corriekay/pokegoutil/BlossomsPoGoManager.java
@@ -1,9 +1,8 @@
package me.corriekay.pokegoutil;

import javafx.application.Application;
import javafx.scene.layout.Pane;
import javafx.stage.Stage;
import me.corriekay.pokegoutil.DATA.controllers.AccountController;
import me.corriekay.pokegoutil.DATA.managers.AccountController;
import me.corriekay.pokegoutil.GUI.controller.ChooseGuiWindowController;
import me.corriekay.pokegoutil.utils.Config;
import me.corriekay.pokegoutil.utils.helpers.UIHelper;
Expand All @@ -23,6 +22,16 @@ public static void main(String[] args) {
launch(args);
}

public static Stage getPrimaryStage() {
return sPrimaryStage;
}

public static void setNewPrimaryStage(Stage stage) {
if (sPrimaryStage != null && sPrimaryStage.isShowing())
sPrimaryStage.hide();
sPrimaryStage = stage;
}

@Override
public void start(Stage primaryStage) {
if (Config.getConfig().getBool("develop", false)) {
Expand All @@ -47,14 +56,4 @@ public void run() {
}
});
}

public static Stage getPrimaryStage(){
return sPrimaryStage;
}

public static void setNewPrimaryStage(Stage stage){
if(sPrimaryStage != null && sPrimaryStage.isShowing())
sPrimaryStage.hide();
sPrimaryStage = stage;
}
}
238 changes: 0 additions & 238 deletions src/me/corriekay/pokegoutil/DATA/controllers/AccountManager.java

This file was deleted.

This file was deleted.

0 comments on commit e955b40

Please sign in to comment.