From 9194522b56b85c7a347cd87fd9d475d8d6f53518 Mon Sep 17 00:00:00 2001 From: rating89us <45968869+rating89us@users.noreply.github.com> Date: Tue, 30 Nov 2021 23:08:37 +0100 Subject: [PATCH] Wizard: display selected network (testnet/stagenet) on "Create a new wallet" header --- wizard/WizardCreateDevice1.qml | 7 ++++++- wizard/WizardCreateWallet1.qml | 7 ++++++- wizard/WizardHome.qml | 14 ++++++++++++-- 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/wizard/WizardCreateDevice1.qml b/wizard/WizardCreateDevice1.qml index 0bdc03ed..9c12c500 100644 --- a/wizard/WizardCreateDevice1.qml +++ b/wizard/WizardCreateDevice1.qml @@ -73,7 +73,12 @@ Rectangle { spacing: 20 WizardHeader { - title: qsTr("Create a new wallet") + translationManager.emptyString + title: { + var nettype = persistentSettings.nettype; + return qsTr("Create a new wallet") + (nettype === 2 ? " (" + qsTr("stagenet") + ")" + : nettype === 1 ? " (" + qsTr("testnet") + ")" + : "") + translationManager.emptyString + } subtitle: qsTr("Using a hardware device.") + translationManager.emptyString } diff --git a/wizard/WizardCreateWallet1.qml b/wizard/WizardCreateWallet1.qml index 088df200..109aa726 100644 --- a/wizard/WizardCreateWallet1.qml +++ b/wizard/WizardCreateWallet1.qml @@ -60,7 +60,12 @@ Rectangle { spacing: 20 WizardHeader { - title: qsTr("Create a new wallet") + translationManager.emptyString + title: { + var nettype = persistentSettings.nettype; + return qsTr("Create a new wallet") + (nettype === 2 ? " (" + qsTr("stagenet") + ")" + : nettype === 1 ? " (" + qsTr("testnet") + ")" + : "") + translationManager.emptyString + } subtitle: qsTr("Creates a new wallet on this computer.") + translationManager.emptyString } diff --git a/wizard/WizardHome.qml b/wizard/WizardHome.qml index 540216e8..ba0a0f11 100644 --- a/wizard/WizardHome.qml +++ b/wizard/WizardHome.qml @@ -73,7 +73,12 @@ Rectangle { } WizardMenuItem { - headerText: qsTr("Create a new wallet") + translationManager.emptyString + headerText: { + var nettype = persistentSettings.nettype; + return qsTr("Create a new wallet") + (nettype === 2 ? " (" + qsTr("stagenet") + ")" + : nettype === 1 ? " (" + qsTr("testnet") + ")" + : "") + translationManager.emptyString + } bodyText: qsTr("Choose this option if this is your first time using Monero.") + translationManager.emptyString imageIcon: "qrc:///images/create-wallet.png" @@ -94,7 +99,12 @@ Rectangle { } WizardMenuItem { - headerText: qsTr("Create a new wallet from hardware") + translationManager.emptyString + headerText: { + var nettype = persistentSettings.nettype; + return qsTr("Create a new wallet from hardware") + (nettype === 2 ? " (" + qsTr("stagenet") + ")" + : nettype === 1 ? " (" + qsTr("testnet") + ")" + : "") + translationManager.emptyString + } bodyText: qsTr("Connect your hardware wallet to create a new Monero wallet.") + translationManager.emptyString imageIcon: "qrc:///images/restore-wallet-from-hardware.png"