Skip to content

Commit

Permalink
Fixed resource paths, added build.bat and run.bat command
Browse files Browse the repository at this point in the history
  • Loading branch information
jonatino committed Oct 23, 2016
1 parent dc50f84 commit a05d9a5
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 4 deletions.
6 changes: 6 additions & 0 deletions build.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
@echo off
cd /d "%~dp0"
title Vision Builder
call gradlew installDist
echo.
pause
16 changes: 16 additions & 0 deletions run.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
@echo off
cd /d "%~dp0"
title Vision

set bat="./build/install/Vision/bin/Vision.bat"

:loop
if exist %bat% (
call %bat%
pause
) else (
call build.bat
cls
title Vision
goto loop
)
2 changes: 1 addition & 1 deletion src/main/kotlin/org/anglur/vision/view/VisionApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class VisionApp : App() {
val view = find(primaryView)
stage.apply {
scene = Scene(view.root)
icons.add(Image(VisionGUI::class.java.getResource("../../../../icon.png").toExternalForm()))
icons.add(Image(VisionGUI::class.java.getResource("img/icon.png").toExternalForm()))
scene.stylesheets.addAll(FX.stylesheets)
show()
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/kotlin/org/anglur/vision/view/VisionGUI.kt
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ class VisionGUI : View() {
val desktopFrame = find(DesktopFrame::class)
val stage = Stage()
stage.title = "Vision - Id: 432 340 439 Name: ${InetAddress.getLocalHost().hostName}"
stage.icons.add(Image(VisionGUI::class.java.getResource("../../../../icon.png").toExternalForm()))
stage.icons.add(Image(VisionGUI::class.java.getResource("img/icon.png").toExternalForm()))
stage.scene = Scene(desktopFrame.root, 1920.0, 1080.0, Color.BLACK)

connect.setOnAction {
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/org/anglur/vision/view/VisionGUI.fxml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0"/>
<ImageView fitHeight="35.0" fitWidth="248.0" layoutX="431.3999938964844" layoutY="11.0" pickOnBounds="true"
preserveRatio="true" AnchorPane.rightAnchor="16.4666748046875" AnchorPane.topAnchor="11.0">
<Image url="@../../../../logo.png"/>
<Image url="@img/logo.png"/>
</ImageView>
<Label layoutX="18.0" layoutY="130.0" prefHeight="35.0" prefWidth="107.0" text="Your ID">
<font>
Expand Down Expand Up @@ -90,7 +90,7 @@
</Label>
<ImageView fitHeight="35.0" fitWidth="37.0" layoutX="557.0" layoutY="318.0" pickOnBounds="true"
preserveRatio="true">
<Image url="@../../../../github.png"/>
<Image url="@img/github.png"/>
</ImageView>
<Label layoutX="384.0" layoutY="314.0" prefHeight="35.0" prefWidth="168.0" text="Check it out on Github! &lt;3">
<font>
Expand Down
File renamed without changes
File renamed without changes
File renamed without changes

0 comments on commit a05d9a5

Please sign in to comment.