Skip to content

Commit

Permalink
Minor Fixes
Browse files Browse the repository at this point in the history
- Correct MS Excel execution command added
  • Loading branch information
Guleri24 committed Mar 13, 2022
1 parent a5fb256 commit 1126631
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 31 deletions.
6 changes: 3 additions & 3 deletions src/main/java/com/horizonxe/MainController.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@

public class MainController {
private static BufferedWriter writer;
private final List<String> projects = new ArrayList<>();
private final List<String> modules = new ArrayList<>();
@FXML
public Button triggerCmd;
@FXML
public ComboBox<String> projectMenu;
@FXML
public ComboBox<String> moduleMenu;
public AnchorPane mainView;
private final List<String> projects = new ArrayList<>();
private final List<String> modules = new ArrayList<>();
private File executableFile;
private File dataFile;
private boolean isWindows;
Expand Down Expand Up @@ -107,7 +107,7 @@ public void triggerCmd() throws IOException {
writer.close();

if (isWindows) {
Runtime.getRuntime().exec("cmd /c start cmd.exe /K \"" + executableFile.getAbsolutePath() + "\"");
Runtime.getRuntime().exec("cmd /c start excel /K \"" + executableFile.getAbsolutePath() + "\"");
stage.close();
} else {
stage.close();
Expand Down
68 changes: 40 additions & 28 deletions src/main/resources/com.horizonxe/fis-form.fxml
Original file line number Diff line number Diff line change
@@ -1,57 +1,69 @@
<?xml version="1.0" encoding="UTF-8"?>

<?import javafx.scene.control.Button?>
<?import javafx.scene.control.ComboBox?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.*?>
<?import javafx.scene.image.Image?>
<?import javafx.scene.image.ImageView?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.BorderPane?>
<?import javafx.scene.layout.Pane?>
<?import javafx.scene.layout.*?>
<?import javafx.scene.shape.Rectangle?>
<?import javafx.scene.text.Font?>

<AnchorPane fx:id="mainView" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="440.0" prefWidth="780.0" xmlns="http://javafx.com/javafx/17" xmlns:fx="http://javafx.com/fxml/1" fx:controller="com.horizonxe.MainController">
<?import javafx.scene.text.*?>
<AnchorPane xmlns:fx="http://javafx.com/fxml/1" fx:id="mainView" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity"
minWidth="-Infinity" prefHeight="440.0" prefWidth="780.0" xmlns="http://javafx.com/javafx/17"
fx:controller="com.horizonxe.MainController">
<BorderPane prefHeight="440.0" prefWidth="780.0">
<left>
<Pane prefHeight="440.0" prefWidth="322.0" style="-fx-background-color: #012834;" stylesheets="@styles.css" BorderPane.alignment="CENTER">
<ImageView fitHeight="53.0" fitWidth="136.0" layoutX="33.0" layoutY="34.0" pickOnBounds="true" preserveRatio="true">
<Image url="@logo.png" />
<Pane prefHeight="440.0" prefWidth="322.0" style="-fx-background-color: #012834;" stylesheets="@styles.css"
BorderPane.alignment="CENTER">
<ImageView fitHeight="53.0" fitWidth="136.0" layoutX="33.0" layoutY="34.0" pickOnBounds="true"
preserveRatio="true">
<Image url="@logo.png"/>
</ImageView>
<Label layoutX="25.0" layoutY="204.0" prefHeight="61.0" prefWidth="269.0" text="ADVANCING THE WAY THE WORLD" textFill="#fcf7f7" wrapText="true">
<Label layoutX="25.0" layoutY="204.0" prefHeight="61.0" prefWidth="269.0"
text="ADVANCING THE WAY THE WORLD" textFill="#fcf7f7" wrapText="true">
<font>
<Font name="System Bold" size="25.0" />
<Font name="System Bold" size="25.0"/>
</font>
</Label>
<Label layoutX="25.0" layoutY="265.0" prefHeight="61.0" prefWidth="269.0" style="-fx-text-fill: #009775;" stylesheets="@styles.css" text="PAYS, BANKS AND INVESTS" textFill="#777c7b" wrapText="true">
<Label layoutX="25.0" layoutY="265.0" prefHeight="61.0" prefWidth="269.0"
style="-fx-text-fill: #009775;" stylesheets="@styles.css" text="PAYS, BANKS AND INVESTS"
textFill="#777c7b" wrapText="true">
<font>
<Font name="System Bold" size="25.0" />
<Font name="System Bold" size="25.0"/>
</font>
</Label>
<Rectangle arcHeight="5.0" arcWidth="5.0" fill="#70cea6" height="4.0" layoutX="25.0" layoutY="337.0" stroke="TRANSPARENT" strokeType="INSIDE" style="-fx-fill: #4bcd3e;" width="41.0" />
<Rectangle arcHeight="5.0" arcWidth="5.0" fill="#70cea6" height="4.0" layoutX="25.0" layoutY="337.0"
stroke="TRANSPARENT" strokeType="INSIDE" style="-fx-fill: #4bcd3e;" width="41.0"/>
</Pane>
</left>
<center>
<Pane prefHeight="440.0" prefWidth="455.0" style="-fx-background-color: #003b4d;" stylesheets="@styles.css" BorderPane.alignment="CENTER">
<ComboBox fx:id="projectMenu" layoutX="204.0" layoutY="126.0" prefHeight="35.0" prefWidth="211.0" stylesheets="@styles.css" />
<Label layoutX="40.0" layoutY="127.0" prefHeight="33.0" prefWidth="137.0" text="Project Name" textFill="WHITE">
<Pane prefHeight="440.0" prefWidth="455.0" style="-fx-background-color: #003b4d;" stylesheets="@styles.css"
BorderPane.alignment="CENTER">
<ComboBox fx:id="projectMenu" layoutX="204.0" layoutY="126.0" prefHeight="35.0" prefWidth="211.0"
stylesheets="@styles.css"/>
<Label layoutX="40.0" layoutY="127.0" prefHeight="33.0" prefWidth="137.0" text="Project Name"
textFill="WHITE">
<font>
<Font name="System Bold" size="16.0" />
<Font name="System Bold" size="16.0"/>
</font>
</Label>
<Label layoutX="41.0" layoutY="189.0" prefHeight="28.0" prefWidth="135.0" text="Module Name" textFill="WHITE">
<Label layoutX="41.0" layoutY="189.0" prefHeight="28.0" prefWidth="135.0" text="Module Name"
textFill="WHITE">
<font>
<Font name="System Bold" size="16.0" />
<Font name="System Bold" size="16.0"/>
</font>
</Label>
<ComboBox fx:id="moduleMenu" layoutX="204.0" layoutY="186.0" prefHeight="35.0" prefWidth="211.0" stylesheets="@styles.css" />
<Button fx:id="triggerCmd" layoutX="310.0" layoutY="266.0" mnemonicParsing="false" onAction="#triggerCmd" prefHeight="30.0" prefWidth="105.0" style="-fx-background-color: #4bcd3e; -fx-background-radius: 70;" stylesheets="@styles.css" text="Trigger">
<ComboBox fx:id="moduleMenu" layoutX="204.0" layoutY="186.0" prefHeight="35.0" prefWidth="211.0"
stylesheets="@styles.css"/>
<Button fx:id="triggerCmd" layoutX="310.0" layoutY="266.0" mnemonicParsing="false"
onAction="#triggerCmd" prefHeight="30.0" prefWidth="105.0"
style="-fx-background-color: #4bcd3e; -fx-background-radius: 70;" stylesheets="@styles.css"
text="Trigger">
<font>
<Font name="System Bold" size="13.0" />
<Font name="System Bold" size="13.0"/>
</font>
</Button>
<Button layoutX="26.0" layoutY="14.0" mnemonicParsing="false" onAction="#addData" prefHeight="24.0" prefWidth="84.0" style="-fx-background-color: #4bcd3e; -fx-background-radius: 70;" stylesheets="@styles.css" text="Add Data" />
<Button layoutX="120.0" layoutY="14.0" mnemonicParsing="false" prefHeight="24.0" prefWidth="65.0" style="-fx-background-color: #4bcd3e; -fx-background-radius: 70;" stylesheets="@styles.css" text="Help" />
<Button layoutX="26.0" layoutY="14.0" mnemonicParsing="false" onAction="#addData" prefHeight="24.0"
prefWidth="84.0" style="-fx-background-color: #4bcd3e; -fx-background-radius: 70;"
stylesheets="@styles.css" text="Add Data"/>
</Pane>
</center>
</BorderPane>
Expand Down

0 comments on commit 1126631

Please sign in to comment.