removed last unnecessary reboot
* needs more testing, especialy under Windows * test on a completly fresh setup
This commit is contained in:
parent
b4fc36621a
commit
b915cf7ad9
|
@ -142,8 +142,6 @@ public class Main extends Application {
|
||||||
mainWindowController.setLastLocalSync(0);
|
mainWindowController.setLastLocalSync(0);
|
||||||
mainWindowController.setxPosHelper(0);
|
mainWindowController.setxPosHelper(0);
|
||||||
mainWindowController.saveSettings();
|
mainWindowController.saveSettings();
|
||||||
Runtime.getRuntime().exec("java -jar cemu_UI.jar"); //TODO check if this really is needed start again (preventing Bugs)
|
|
||||||
System.exit(0); //finishes itself
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!pictureCache.exists()) {
|
if (!pictureCache.exists()) {
|
||||||
|
|
|
@ -290,7 +290,7 @@ public class MainWindowController {
|
||||||
private String selectedGameTitle;
|
private String selectedGameTitle;
|
||||||
private String id;
|
private String id;
|
||||||
private String version = "0.3.0";
|
private String version = "0.3.0";
|
||||||
private String buildNumber = "075";
|
private String buildNumber = "077";
|
||||||
private String versionName = "Puzzle Plank Galaxy";
|
private String versionName = "Puzzle Plank Galaxy";
|
||||||
private int xPos = -200;
|
private int xPos = -200;
|
||||||
private int yPos = 17;
|
private int yPos = 17;
|
||||||
|
@ -719,7 +719,7 @@ public class MainWindowController {
|
||||||
try {
|
try {
|
||||||
Desktop.getDesktop().browse(new URI("https://github.com/Seil0/cemu_UI/issues/3"));
|
Desktop.getDesktop().browse(new URI("https://github.com/Seil0/cemu_UI/issues/3"));
|
||||||
} catch (IOException | URISyntaxException e) {
|
} catch (IOException | URISyntaxException e) {
|
||||||
e.printStackTrace();
|
LOGGER.error("An error ocoured while trying to open a Website.", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -1297,7 +1297,6 @@ public class MainWindowController {
|
||||||
|
|
||||||
//remove all games from gamesAnchorPane and add them afterwards
|
//remove all games from gamesAnchorPane and add them afterwards
|
||||||
public void refreshUIData() {
|
public void refreshUIData() {
|
||||||
System.out.println("refresh");
|
|
||||||
//remove all games form gamesAnchorPane
|
//remove all games form gamesAnchorPane
|
||||||
gamesAnchorPane.getChildren().removeAll(gamesAnchorPane.getChildren());
|
gamesAnchorPane.getChildren().removeAll(gamesAnchorPane.getChildren());
|
||||||
|
|
||||||
|
@ -1544,6 +1543,8 @@ public class MainWindowController {
|
||||||
|
|
||||||
/**FIXME somehow the window width is set to 8, if we can find a way to get always the real window with
|
/**FIXME somehow the window width is set to 8, if we can find a way to get always the real window with
|
||||||
*(at the beginning we have to use prefWidth after resizing Width) we can remove this
|
*(at the beginning we have to use prefWidth after resizing Width) we can remove this
|
||||||
|
*This is caused by the time the game objects are generates,
|
||||||
|
*it's before the window is opened so it's size is > 10
|
||||||
*/
|
*/
|
||||||
if (mainAnchorPane.getWidth() < 10) {
|
if (mainAnchorPane.getWidth() < 10) {
|
||||||
xPosHelperMax = (int) Math.floor((mainAnchorPane.getPrefWidth() - 36) / 217);
|
xPosHelperMax = (int) Math.floor((mainAnchorPane.getPrefWidth() - 36) / 217);
|
||||||
|
|
|
@ -149,7 +149,7 @@ public class UpdateController implements Runnable {
|
||||||
FileUtils.copyInputStreamToFile(pmis, new File("cemu_UI_update.jar")); // download update
|
FileUtils.copyInputStreamToFile(pmis, new File("cemu_UI_update.jar")); // download update
|
||||||
org.apache.commons.io.FileUtils.copyFile(new File("cemu_UI_update.jar"), new File("cemu_UI.jar"));
|
org.apache.commons.io.FileUtils.copyFile(new File("cemu_UI_update.jar"), new File("cemu_UI.jar"));
|
||||||
org.apache.commons.io.FileUtils.deleteQuietly(new File("cemu_UI_update.jar")); // delete update
|
org.apache.commons.io.FileUtils.deleteQuietly(new File("cemu_UI_update.jar")); // delete update
|
||||||
Runtime.getRuntime().exec("java -jar cemu_UI.jar"); // start again
|
Runtime.getRuntime().exec("java -jar cemu_UI.jar"); // start again TODO consider ProcessBuilder to execute
|
||||||
System.exit(0); // finishes itself
|
System.exit(0); // finishes itself
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
Platform.runLater(() -> {
|
Platform.runLater(() -> {
|
||||||
|
|
Loading…
Reference in New Issue