feat: add purchase link

This commit is contained in:
huanghongxun
2021-09-18 20:00:06 +08:00
parent 3513c1a431
commit 223c45130f
4 changed files with 19 additions and 3 deletions

View File

@@ -276,7 +276,9 @@ public class CreateAccountPane extends JFXDialogLayout implements DialogAware {
birthLink.setOnAction(e -> FXUtils.openLink("https://support.microsoft.com/zh-cn/account-billing/如何更改-microsoft-帐户上的出生日期-837badbc-999e-54d2-2617-d19206b9540a"));
JFXHyperlink profileLink = new JFXHyperlink(i18n("account.methods.microsoft.profile"));
profileLink.setOnAction(e -> FXUtils.openLink("https://account.live.com/editprof.aspx"));
box.getChildren().setAll(profileLink, birthLink);
JFXHyperlink purchaseLink = new JFXHyperlink(i18n("account.methods.yggdrasil.purchase"));
purchaseLink.setOnAction(e -> FXUtils.openLink("https://www.minecraft.net/zh-hans/store/minecraft-java-edition"));
box.getChildren().setAll(profileLink, birthLink, purchaseLink);
GridPane.setColumnSpan(box, 2);
vbox.getChildren().setAll(hintPane, box);
@@ -415,17 +417,28 @@ public class CreateAccountPane extends JFXDialogLayout implements DialogAware {
if (factory instanceof YggdrasilAccountFactory) {
HBox box = new HBox();
GridPane.setColumnSpan(box, 2);
JFXHyperlink migrationLink = new JFXHyperlink(i18n("account.methods.yggdrasil.migration"));
migrationLink.setOnAction(e -> FXUtils.openLink("https://help.minecraft.net/hc/en-us/articles/360050865492-JAVA-Account-Migration-FAQ"));
GridPane.setColumnSpan(box, 2);
box.getChildren().setAll(migrationLink);
JFXHyperlink purchaseLink = new JFXHyperlink(i18n("account.methods.yggdrasil.purchase"));
purchaseLink.setOnAction(e -> FXUtils.openLink("https://www.minecraft.net/zh-hans/store/minecraft-java-edition"));
box.getChildren().setAll(migrationLink, purchaseLink);
add(box, 0, rowIndex);
rowIndex++;
}
if (factory instanceof OfflineAccountFactory) {
JFXHyperlink purchaseLink = new JFXHyperlink(i18n("account.methods.yggdrasil.purchase"));
purchaseLink.setOnAction(e -> FXUtils.openLink("https://www.minecraft.net/zh-hans/store/minecraft-java-edition"));
HBox linkPane = new HBox(purchaseLink);
GridPane.setColumnSpan(linkPane, 2);
add(linkPane, 0, rowIndex);
rowIndex++;
HBox box = new HBox();
MenuUpDownButton advancedButton = new MenuUpDownButton();
box.getChildren().setAll(advancedButton);

View File

@@ -94,6 +94,7 @@ account.methods.offline.uuid.hint=UUID is the unique identifier to the game char
account.methods.offline.uuid.malformed=Malformed
account.methods.yggdrasil=Mojang
account.methods.yggdrasil.migration=How to migrate to Microsoft Account?
account.methods.yggdrasil.purchase=Purchase Minecraft
account.missing=No Account
account.missing.add=Click here to add
account.not_logged_in=Not logged in

View File

@@ -94,6 +94,7 @@ account.methods.offline.uuid.hint=UUID 是 Minecraft 對玩家角色的唯一標
account.methods.offline.uuid.malformed=格式錯誤
account.methods.yggdrasil=正版登入
account.methods.yggdrasil.migration=如何遷移至微軟帳戶?
account.methods.yggdrasil.purchase=購買 Minecraft
account.missing=沒有遊戲帳戶
account.missing.add=按一下此處加入帳戶
account.not_logged_in=未登入

View File

@@ -94,6 +94,7 @@ account.methods.offline.uuid.hint=UUID 是 Minecraft 对玩家角色的唯一标
account.methods.offline.uuid.malformed=格式错误
account.methods.yggdrasil=Mojang 帐户
account.methods.yggdrasil.migration=如何迁移至微软帐户?
account.methods.yggdrasil.purchase=购买 Minecraft
account.missing=没有游戏帐户
account.missing.add=点击此处添加帐户
account.not_logged_in=未登录