Remove isFirstLaunch
This commit is contained in:
@@ -143,9 +143,6 @@ public final class Config implements Cloneable, Observable {
|
|||||||
@SerializedName("logLines")
|
@SerializedName("logLines")
|
||||||
private IntegerProperty logLines = new SimpleIntegerProperty(100);
|
private IntegerProperty logLines = new SimpleIntegerProperty(100);
|
||||||
|
|
||||||
@SerializedName("firstLaunch")
|
|
||||||
private BooleanProperty firstLaunch = new SimpleBooleanProperty(true);
|
|
||||||
|
|
||||||
@SerializedName("authlibInjectorServers")
|
@SerializedName("authlibInjectorServers")
|
||||||
private ObservableList<AuthlibInjectorServer> authlibInjectorServers = FXCollections.observableArrayList();
|
private ObservableList<AuthlibInjectorServer> authlibInjectorServers = FXCollections.observableArrayList();
|
||||||
|
|
||||||
@@ -431,18 +428,6 @@ public final class Config implements Cloneable, Observable {
|
|||||||
return logLines;
|
return logLines;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isFirstLaunch() {
|
|
||||||
return firstLaunch.get();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setFirstLaunch(boolean firstLaunch) {
|
|
||||||
this.firstLaunch.set(firstLaunch);
|
|
||||||
}
|
|
||||||
|
|
||||||
public BooleanProperty firstLaunchProperty() {
|
|
||||||
return firstLaunch;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ObservableList<AuthlibInjectorServer> getAuthlibInjectorServers() {
|
public ObservableList<AuthlibInjectorServer> getAuthlibInjectorServers() {
|
||||||
return authlibInjectorServers;
|
return authlibInjectorServers;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -50,11 +50,7 @@ public class Settings {
|
|||||||
instance = new Settings();
|
instance = new Settings();
|
||||||
}
|
}
|
||||||
|
|
||||||
private final boolean firstLaunch;
|
|
||||||
|
|
||||||
private Settings() {
|
private Settings() {
|
||||||
firstLaunch = config().isFirstLaunch();
|
|
||||||
|
|
||||||
ProxyManager.init();
|
ProxyManager.init();
|
||||||
Accounts.init();
|
Accounts.init();
|
||||||
|
|
||||||
@@ -67,11 +63,6 @@ public class Settings {
|
|||||||
}
|
}
|
||||||
|
|
||||||
config().addListener(source -> ConfigHolder.saveConfig());
|
config().addListener(source -> ConfigHolder.saveConfig());
|
||||||
config().setFirstLaunch(false);
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean isFirstLaunch() {
|
|
||||||
return firstLaunch;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private Locales.SupportedLocale locale = Locales.getLocaleByName(config().getLocalization());
|
private Locales.SupportedLocale locale = Locales.getLocaleByName(config().getLocalization());
|
||||||
|
|||||||
@@ -200,7 +200,7 @@ public final class Decorator extends StackPane implements TaskExecutorDialogWiza
|
|||||||
);
|
);
|
||||||
nowAnimation.play();
|
nowAnimation.play();
|
||||||
});
|
});
|
||||||
if (!Settings.instance().isFirstLaunch() || Settings.instance().getLocale().getLocale() != Locale.CHINA)
|
if (/* TODO: is not first launch or */Settings.instance().getLocale().getLocale() != Locale.CHINA)
|
||||||
drawerWrapper.getChildren().remove(welcomeView);
|
drawerWrapper.getChildren().remove(welcomeView);
|
||||||
|
|
||||||
if (!min) buttonsContainer.getChildren().remove(btnMin);
|
if (!min) buttonsContainer.getChildren().remove(btnMin);
|
||||||
|
|||||||
Reference in New Issue
Block a user