mirror of
https://github.com/2OOP/pism.git
synced 2026-02-04 19:04:49 +00:00
save locale
This commit is contained in:
@@ -13,12 +13,8 @@ import javafx.application.Application;
|
|||||||
import javafx.scene.Scene;
|
import javafx.scene.Scene;
|
||||||
import javafx.scene.layout.StackPane;
|
import javafx.scene.layout.StackPane;
|
||||||
import javafx.stage.Stage;
|
import javafx.stage.Stage;
|
||||||
import org.toop.framework.asset.resources.SettingsAsset;
|
|
||||||
import org.toop.framework.audio.events.AudioEvents;
|
|
||||||
import org.toop.framework.eventbus.EventFlow;
|
|
||||||
import org.toop.local.AppSettings;
|
import org.toop.local.AppSettings;
|
||||||
|
|
||||||
import java.io.File;
|
|
||||||
import java.util.Stack;
|
import java.util.Stack;
|
||||||
|
|
||||||
public final class App extends Application {
|
public final class App extends Application {
|
||||||
@@ -27,7 +23,6 @@ public final class App extends Application {
|
|||||||
private static Stack<Layer> stack;
|
private static Stack<Layer> stack;
|
||||||
private static int height;
|
private static int height;
|
||||||
private static int width;
|
private static int width;
|
||||||
private static SettingsAsset settingsAsset;
|
|
||||||
|
|
||||||
private static boolean isQuitting;
|
private static boolean isQuitting;
|
||||||
|
|
||||||
@@ -75,6 +70,7 @@ public final class App extends Application {
|
|||||||
|
|
||||||
App.isQuitting = false;
|
App.isQuitting = false;
|
||||||
|
|
||||||
|
new EventFlow().addPostEvent(new AudioEvents.StartBackgroundMusic()).asyncPostEvent();
|
||||||
activate(new MainLayer());
|
activate(new MainLayer());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -64,6 +64,7 @@ public final class OptionsLayer extends Layer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
AppContext.setLocale(locale);
|
AppContext.setLocale(locale);
|
||||||
|
settings.setLocale(locale.toString());
|
||||||
App.reloadAll();
|
App.reloadAll();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user