Change default profile directory to ".minecraft"

This commit is contained in:
huanghongxun
2018-10-02 18:34:09 +08:00
parent 8e1e13058b
commit 2fa08e0a70
5 changed files with 6 additions and 2 deletions

View File

@@ -36,6 +36,7 @@ import org.jackhuang.hmcl.ui.decorator.DecoratorPage;
import org.jackhuang.hmcl.util.StringUtils;
import java.io.File;
import java.nio.file.Paths;
import java.util.Optional;
import static org.jackhuang.hmcl.util.i18n.I18n.i18n;
@@ -60,7 +61,7 @@ public final class ProfilePage extends StackPane implements DecoratorPage {
title = new ReadOnlyStringWrapper(this, "title",
profile == null ? i18n("profile.new") : i18n("profile") + " - " + profileDisplayName);
location = new SimpleStringProperty(this, "location",
Optional.ofNullable(profile).map(Profile::getGameDir).map(File::getAbsolutePath).orElse(""));
Optional.ofNullable(profile).map(Profile::getGameDir).map(File::getAbsolutePath).orElse(".minecraft"));
FXUtils.loadFXML(this, "/assets/fxml/profile.fxml");

View File

@@ -21,7 +21,7 @@
<BorderPane> <!-- Name -->
<left>
<VBox>
<Label text="%profile" BorderPane.alignment="CENTER_LEFT"/>
<Label text="%profile.name" BorderPane.alignment="CENTER_LEFT"/>
</VBox>
</left>
<right>

View File

@@ -273,6 +273,7 @@ profile.home=User home
profile.instance_directory=Game Directory
profile.instance_directory.choose=Choose Game Directory
profile.manage=Game Directory List
profile.name=Name
profile.new=New Config
profile.title=Game Directories
profile.selected=Selected

View File

@@ -273,6 +273,7 @@ profile.home=官方啟動器
profile.instance_directory=遊戲路徑
profile.instance_directory.choose=選擇遊戲路徑
profile.manage=遊戲目錄列表
profile.name=名稱
profile.new=建立設定
profile.title=遊戲目錄
profile.selected=已選取

View File

@@ -273,6 +273,7 @@ profile.home=官方启动器
profile.instance_directory=游戏路径
profile.instance_directory.choose=选择游戏路径
profile.manage=游戏目录列表
profile.name=名称
profile.new=新建配置
profile.title=游戏目录
profile.selected=已选中