fix: ensure `onSelectedRecipientChanged` signal is emitted

This commit is contained in:
Pascal Precht 2020-10-29 15:03:55 +01:00 committed by Iuri Matias
parent 5ac4162f82
commit 968477b43f
2 changed files with 6 additions and 3 deletions

View File

@ -140,7 +140,8 @@ Item {
anchors.topMargin: Style.current.halfPadding anchors.topMargin: Style.current.halfPadding
onResolved: { onResolved: {
root.isResolvedAddress = true root.isResolvedAddress = true
root.selectedContact.address = resolvedAddress const { name, alias, isContact, identicon, ensVerified } = root.selectedContact
root.selectedContact = { address: resolvedAddress, name, alias, isContact, identicon, ensVerified }
validate() validate()
} }
onIsPendingChanged: { onIsPendingChanged: {

View File

@ -169,8 +169,10 @@ Item {
if (!selAddressSource.selectedSource || (selAddressSource.selectedSource && selAddressSource.selectedSource.value !== RecipientSelector.Type.Address)) { if (!selAddressSource.selectedSource || (selAddressSource.selectedSource && selAddressSource.selectedSource.value !== RecipientSelector.Type.Address)) {
return return
} }
root.selectedRecipient.address = selectedAddress var recipient = root.selectedRecipient;
root.selectedRecipient.type = RecipientSelector.Type.Address recipient.address = selectedAddress
recipient.type = RecipientSelector.Type.Address
root.selectedRecipient = recipient
} }
onIsValidChanged: root.validate() onIsValidChanged: root.validate()
} }