|
|
|
@ -85,38 +85,6 @@ WizardComponent { |
|
|
|
id: mainLayout |
|
|
|
id: mainLayout |
|
|
|
width: parent.width |
|
|
|
width: parent.width |
|
|
|
|
|
|
|
|
|
|
|
Label { |
|
|
|
|
|
|
|
text: qsTr('Script type and Derivation path') |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
Pane { |
|
|
|
|
|
|
|
Layout.alignment: Qt.AlignHCenter |
|
|
|
|
|
|
|
padding: 0 |
|
|
|
|
|
|
|
visible: !isMultisig |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
FlatButton { |
|
|
|
|
|
|
|
text: qsTr('Detect Existing Accounts') |
|
|
|
|
|
|
|
onClicked: { |
|
|
|
|
|
|
|
var dialog = bip39recoveryDialog.createObject(mainLayout, { |
|
|
|
|
|
|
|
walletType: wizard_data['wallet_type'], |
|
|
|
|
|
|
|
seed: wizard_data['seed'], |
|
|
|
|
|
|
|
seedExtraWords: wizard_data['seed_extra_words'] |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
dialog.accepted.connect(function () { |
|
|
|
|
|
|
|
// select matching script type button and set derivation path |
|
|
|
|
|
|
|
for (var i = 0; i < scripttypegroup.buttons.length; i++) { |
|
|
|
|
|
|
|
var btn = scripttypegroup.buttons[i] |
|
|
|
|
|
|
|
if (btn.visible && btn.scripttype == dialog.scriptType) { |
|
|
|
|
|
|
|
btn.checked = true |
|
|
|
|
|
|
|
derivationpathtext.text = dialog.derivationPath |
|
|
|
|
|
|
|
return |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
dialog.open() |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Label { |
|
|
|
Label { |
|
|
|
text: qsTr('Choose the type of addresses in your wallet.') |
|
|
|
text: qsTr('Choose the type of addresses in your wallet.') |
|
|
|
} |
|
|
|
} |
|
|
|
@ -164,17 +132,55 @@ WizardComponent { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
InfoTextArea { |
|
|
|
InfoTextArea { |
|
|
|
Layout.preferredWidth: parent.width |
|
|
|
Layout.fillWidth: true |
|
|
|
text: qsTr('You can override the suggested derivation path.') + ' ' + |
|
|
|
text: qsTr('You can override the suggested derivation path.') + ' ' + |
|
|
|
qsTr('If you are not sure what this is, leave this field unchanged.') |
|
|
|
qsTr('If you are not sure what this is, leave this field unchanged.') |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Label { |
|
|
|
|
|
|
|
text: qsTr('Derivation path') |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
TextField { |
|
|
|
TextField { |
|
|
|
id: derivationpathtext |
|
|
|
id: derivationpathtext |
|
|
|
Layout.fillWidth: true |
|
|
|
Layout.fillWidth: true |
|
|
|
placeholderText: qsTr('Derivation path') |
|
|
|
Layout.leftMargin: constants.paddingMedium |
|
|
|
onTextChanged: validate() |
|
|
|
onTextChanged: validate() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Pane { |
|
|
|
|
|
|
|
Layout.alignment: Qt.AlignHCenter |
|
|
|
|
|
|
|
Layout.topMargin: constants.paddingLarge |
|
|
|
|
|
|
|
padding: 0 |
|
|
|
|
|
|
|
visible: !isMultisig |
|
|
|
|
|
|
|
background: Rectangle { |
|
|
|
|
|
|
|
color: Qt.lighter(Material.dialogColor, 1.5) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
FlatButton { |
|
|
|
|
|
|
|
text: qsTr('Detect Existing Accounts') |
|
|
|
|
|
|
|
onClicked: { |
|
|
|
|
|
|
|
var dialog = bip39recoveryDialog.createObject(mainLayout, { |
|
|
|
|
|
|
|
walletType: wizard_data['wallet_type'], |
|
|
|
|
|
|
|
seed: wizard_data['seed'], |
|
|
|
|
|
|
|
seedExtraWords: wizard_data['seed_extra_words'] |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
dialog.accepted.connect(function () { |
|
|
|
|
|
|
|
// select matching script type button and set derivation path |
|
|
|
|
|
|
|
for (var i = 0; i < scripttypegroup.buttons.length; i++) { |
|
|
|
|
|
|
|
var btn = scripttypegroup.buttons[i] |
|
|
|
|
|
|
|
if (btn.visible && btn.scripttype == dialog.scriptType) { |
|
|
|
|
|
|
|
btn.checked = true |
|
|
|
|
|
|
|
derivationpathtext.text = dialog.derivationPath |
|
|
|
|
|
|
|
return |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
dialog.open() |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|