diff --git a/src/app/modules/main/module.nim b/src/app/modules/main/module.nim index 695232adbe..8c9546984b 100644 --- a/src/app/modules/main/module.nim +++ b/src/app/modules/main/module.nim @@ -449,6 +449,10 @@ proc connectForNotificationsOnly[T](self: Module[T]) = let args = AccountArgs(e) self.view.showToastAccountAdded(args.account.name) + self.events.on(SIGNAL_WALLET_ACCOUNT_DELETED) do(e:Args): + let args = AccountArgs(e) + self.view.showToastAccountRemoved(args.account.name) + self.events.on(SIGNAL_KEYPAIR_NAME_CHANGED) do(e: Args): let args = KeypairArgs(e) self.view.showToastKeypairRenamed(args.oldKeypairName, args.keypair.name) diff --git a/src/app/modules/main/view.nim b/src/app/modules/main/view.nim index 7db0bf7651..ec842bb79a 100644 --- a/src/app/modules/main/view.nim +++ b/src/app/modules/main/view.nim @@ -294,6 +294,7 @@ QtObject: ## Signals for in app (ephemeral) notifications proc showToastAccountAdded*(self: View, name: string) {.signal.} + proc showToastAccountRemoved*(self: View, name: string) {.signal.} proc showToastKeypairRenamed*(self: View, oldName: string, newName: string) {.signal.} proc showNetworkEndpointUpdated*(self: View, name: string, isTest: bool, revertedToDefault: bool) {.signal.} proc showToastKeypairRemoved*(self: View, keypairName: string) {.signal.} diff --git a/ui/app/mainui/AppMain.qml b/ui/app/mainui/AppMain.qml index 4bf5af258f..ac431d92c7 100644 --- a/ui/app/mainui/AppMain.qml +++ b/ui/app/mainui/AppMain.qml @@ -120,6 +120,17 @@ Item { ) } + function onShowToastAccountRemoved(name: string) { + Global.displayToastMessage( + qsTr("\"%1\" successfully removed").arg(name), + "", + "checkmark-circle", + false, + Constants.ephemeralNotificationType.success, + "" + ) + } + function onShowToastKeypairRenamed(oldName: string, newName: string) { Global.displayToastMessage( qsTr("You successfully renamed your keypair\nfrom \"%1\" to \"%2\"").arg(oldName).arg(newName),