commit f399f97f10307e7e41eb37c06aee1f8ddc9bac1d parent 1beb2dd32f541086afc1174976e67af3ca33298e Author: Marc Stibane <marc@taler.net> Date: Tue, 22 Jul 2025 11:33:58 +0200 secondAmount is sufficient Diffstat:
6 files changed, 5 insertions(+), 10 deletions(-)
diff --git a/TalerWallet1/Views/OIM/OIMEditView.swift b/TalerWallet1/Views/OIM/OIMEditView.swift @@ -92,7 +92,6 @@ struct OIMEditView: View { VStack { OIMtitleView(cash: cash, amount: available, - isSending: true, history: false, secondAmount: amountToTransfer) Spacer() diff --git a/TalerWallet1/Views/OIM/OIMSubjectView.swift b/TalerWallet1/Views/OIM/OIMSubjectView.swift @@ -94,7 +94,6 @@ struct OIMSubjectView: View { VStack { OIMtitleView(cash: cash, amount: available, - isSending: true, history: false, secondAmount: amountToTransfer) Spacer() diff --git a/TalerWallet1/Views/OIM/OIMbalances.swift b/TalerWallet1/Views/OIM/OIMbalances.swift @@ -189,12 +189,11 @@ struct OIMbalances: View { ZStack(alignment: .top) { topButtons VStack { - let isSending = viewState == .sending + // balance, amountToSend OIMtitleView(cash: cash, amount: available, - isSending: isSending, history: viewState == .historyShown, - secondAmount: nil) + secondAmount: nil) // appears in OIMEditView Spacer() let isOpen = selectedChestIndex != nil ZStack { diff --git a/TalerWallet1/Views/OIM/OIMp2pReceiveView.swift b/TalerWallet1/Views/OIM/OIMp2pReceiveView.swift @@ -42,7 +42,6 @@ struct OIMp2pReceiveView: View { VStack { OIMtitleView(cash: cash, amount: effective, - isSending: false, history: false, secondAmount: nil) Spacer() diff --git a/TalerWallet1/Views/OIM/OIMtransactions.swift b/TalerWallet1/Views/OIM/OIMtransactions.swift @@ -70,7 +70,6 @@ struct OIMtransactions: View { VStack { OIMtitleView(cash: cash, amount: available, - isSending: false, history: true, //viewState == .historyShown, secondAmount: nil) Spacer() diff --git a/TalerWallet1/Views/OIM/OIMviews.swift b/TalerWallet1/Views/OIM/OIMviews.swift @@ -65,7 +65,6 @@ struct OIMnavBack<Content: View>: View { struct OIMtitleView: View { let cash: OIMcash let amount: Amount? - let isSending: Bool let history: Bool let secondAmount: Amount? @@ -85,13 +84,14 @@ struct OIMtitleView: View { if history { Spacer() } + // balance OIMamountV(amount: amount, currencyName: cash.currency.currency) if !history { - if isSending { + if let secondAmount { Spacer() + // amountToSend OIMamountV(amount: secondAmount, currencyName: cash.currency.currency) } - // invisible - source for money (target) flying out of and back in the open chest OIMactionButton(type: .sendP2P, isFinal: false, action: nil) .frame(width: OIMactionSize, height: OIMbuttonSize)