gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-taler-ios] 06/32: More CallStack for Debugging


From: gnunet
Subject: [taler-taler-ios] 06/32: More CallStack for Debugging
Date: Mon, 16 Oct 2023 00:03:04 +0200

This is an automated email from the git hooks/post-receive script.

marc-stibane pushed a commit to branch master
in repository taler-ios.

commit 38a00b98662986c28f7e54b1f23dc611950bc94d
Author: Marc Stibane <marc@taler.net>
AuthorDate: Fri Oct 13 08:03:40 2023 +0200

    More CallStack for Debugging
---
 TalerWallet1/Controllers/DebugViewC.swift              |  2 +-
 TalerWallet1/Views/Balances/BalancesListView.swift     |  4 ++--
 TalerWallet1/Views/Exchange/ExchangeListView.swift     |  2 +-
 TalerWallet1/Views/Exchange/ManualWithdraw.swift       |  9 +++++----
 TalerWallet1/Views/Exchange/ManualWithdrawDone.swift   |  2 +-
 TalerWallet1/Views/HelperViews/ToSButtonView.swift     | 10 ++++++----
 TalerWallet1/Views/Main/MainView.swift                 | 18 ++++++++++--------
 TalerWallet1/Views/Main/SideBarView.swift              |  4 ++--
 TalerWallet1/Views/Main/WalletEmptyView.swift          |  5 +++--
 TalerWallet1/Views/Peer2peer/PaymentPurpose.swift      |  2 +-
 TalerWallet1/Views/Peer2peer/RequestPayment.swift      |  2 +-
 TalerWallet1/Views/Peer2peer/SendAmount.swift          |  2 +-
 TalerWallet1/Views/Peer2peer/SendPurpose.swift         |  2 +-
 .../Views/Settings/Pending/PendingOpsListView.swift    |  6 ++++--
 TalerWallet1/Views/Settings/SettingsView.swift         |  9 +++++----
 .../Views/Sheets/P2P_Sheets/P2pReceiveURIView.swift    |  7 ++++---
 .../WithdrawBankIntegrated/WithdrawTOSView.swift       |  3 ++-
 .../WithdrawBankIntegrated/WithdrawURIView.swift       |  7 ++++---
 .../Views/Transactions/TransactionDetailView.swift     |  2 +-
 .../Views/Transactions/TransactionsEmptyView.swift     |  5 +++--
 .../Views/Transactions/TransactionsListView.swift      |  4 ++--
 21 files changed, 60 insertions(+), 47 deletions(-)

diff --git a/TalerWallet1/Controllers/DebugViewC.swift 
b/TalerWallet1/Controllers/DebugViewC.swift
index b1dee53..78ef45b 100644
--- a/TalerWallet1/Controllers/DebugViewC.swift
+++ b/TalerWallet1/Controllers/DebugViewC.swift
@@ -146,7 +146,7 @@ class DebugViewC: ObservableObject {
     @Published var viewID: Int = 0
     @Published var sheetID: Int = 0
 
-    @MainActor func setViewID(_ newID: Int) -> Void {
+    @MainActor func setViewID(_ newID: Int, stack: CallStack) -> Void {
         if developerMode {
             if viewID == 0 {
                 symLog.log("switching ON, \(newID)")
diff --git a/TalerWallet1/Views/Balances/BalancesListView.swift 
b/TalerWallet1/Views/Balances/BalancesListView.swift
index f1b091e..d75f30d 100644
--- a/TalerWallet1/Views/Balances/BalancesListView.swift
+++ b/TalerWallet1/Views/Balances/BalancesListView.swift
@@ -92,7 +92,7 @@ struct BalancesListView: View {
                                 trailing: QRButton(action: 
checkCameraAvailable))
             .overlay {
                 if balances.isEmpty {
-                    WalletEmptyView()
+                    WalletEmptyView(stack: stack.push())
                         .refreshable {  // already async
                             symLog.log("empty refreshing")
                             let count = await reloadAction(stack.push("empty 
refreshing"))
@@ -109,7 +109,7 @@ struct BalancesListView: View {
                                     dismissAlertButton },
                        message: {   Text("Please allow camera access in 
settings.") })
             .onAppear() {
-                DebugViewC.shared.setViewID(VIEW_BALANCES)
+                DebugViewC.shared.setViewID(VIEW_BALANCES, stack: 
stack.push("onAppear"))
             }
             .sheet(isPresented: $showQRScanner) {
                 let sheet = AnyView(QRSheet(stack: stack.push()))
diff --git a/TalerWallet1/Views/Exchange/ExchangeListView.swift 
b/TalerWallet1/Views/Exchange/ExchangeListView.swift
index 3d1a1f2..36bd726 100644
--- a/TalerWallet1/Views/Exchange/ExchangeListView.swift
+++ b/TalerWallet1/Views/Exchange/ExchangeListView.swift
@@ -124,7 +124,7 @@ extension ExchangeListView {
                 .listStyle(myListStyle.style).anyView
             }
             .onAppear() {
-                DebugViewC.shared.setViewID(VIEW_EXCHANGES)
+                DebugViewC.shared.setViewID(VIEW_EXCHANGES, stack: 
stack.push())
             }
             .onNotification(.ExchangeAdded) { notification in
                 // doesn't need to be received on main thread because we just 
reload in the background anyway
diff --git a/TalerWallet1/Views/Exchange/ManualWithdraw.swift 
b/TalerWallet1/Views/Exchange/ManualWithdraw.swift
index 4d689c1..78356be 100644
--- a/TalerWallet1/Views/Exchange/ManualWithdraw.swift
+++ b/TalerWallet1/Views/Exchange/ManualWithdraw.swift
@@ -62,9 +62,10 @@ struct ManualWithdraw: View {
                             .buttonStyle(TalerButtonStyle(type: .prominent))
                             .padding(.horizontal)
                         } else {
-                            ToSButtonView(exchangeBaseUrl: 
exchange.exchangeBaseUrl,
-                                                   viewID: VIEW_WITHDRAW_TOS,
-                                                      p2p: false)
+                            ToSButtonView(stack: stack.push(),
+                                exchangeBaseUrl: exchange.exchangeBaseUrl,
+                                         viewID: VIEW_WITHDRAW_TOS,
+                                            p2p: false)
                         }
                     }
                 } // disabled
@@ -77,7 +78,7 @@ struct ManualWithdraw: View {
         .navigationTitle(navTitle)
         .onAppear {
             symLog.log("onAppear")
-            DebugViewC.shared.setViewID(VIEW_WITHDRAWAL)
+            DebugViewC.shared.setViewID(VIEW_WITHDRAWAL, stack: stack.push())
         }
         .task(id: centsToTransfer) { // re-run this whenever centsToTransfer 
changes
             let amount = Amount.amountFromCents(currency, centsToTransfer)
diff --git a/TalerWallet1/Views/Exchange/ManualWithdrawDone.swift 
b/TalerWallet1/Views/Exchange/ManualWithdrawDone.swift
index df5b3b1..1a182fa 100644
--- a/TalerWallet1/Views/Exchange/ManualWithdrawDone.swift
+++ b/TalerWallet1/Views/Exchange/ManualWithdrawDone.swift
@@ -50,7 +50,7 @@ struct ManualWithdrawDone: View {
             }
         }.onAppear() {
             symLog.log("onAppear")
-            DebugViewC.shared.setViewID(VIEW_WITHDRAW_ACCEPT)
+            DebugViewC.shared.setViewID(VIEW_WITHDRAW_ACCEPT, stack: 
stack.push())
         }.task {
             do {
                 let amount = Amount.amountFromCents(exchange.currency!, 
centsToTransfer)
diff --git a/TalerWallet1/Views/HelperViews/ToSButtonView.swift 
b/TalerWallet1/Views/HelperViews/ToSButtonView.swift
index 1bcfb76..45a2a91 100644
--- a/TalerWallet1/Views/HelperViews/ToSButtonView.swift
+++ b/TalerWallet1/Views/HelperViews/ToSButtonView.swift
@@ -9,6 +9,7 @@
 import SwiftUI
 
 struct ToSButtonView: View {
+    let stack: CallStack
     let exchangeBaseUrl: String?
     let viewID: Int         // either VIEW_WITHDRAW_TOS or SHEET_WITHDRAW_TOS
     let p2p: Bool
@@ -21,9 +22,10 @@ struct ToSButtonView: View {
             .multilineTextAlignment(.leading)
             .padding()
         NavigationLink(destination: LazyView {
-            WithdrawTOSView(exchangeBaseUrl: exchangeBaseUrl,
-                                     viewID: viewID,
-                               acceptAction: nil)         // pop back to here
+            WithdrawTOSView(stack: stack.push(),
+                  exchangeBaseUrl: exchangeBaseUrl,
+                           viewID: viewID,
+                     acceptAction: nil)         // pop back to here
         }) {
             Text("Terms of Service")  // VIEW_WITHDRAW_TOS
         }.buttonStyle(TalerButtonStyle(type: .prominent))
@@ -32,5 +34,5 @@ struct ToSButtonView: View {
 }
 
 #Preview {
-    ToSButtonView(exchangeBaseUrl: nil, viewID: 0, p2p: false)
+    ToSButtonView(stack: CallStack("Preview"), exchangeBaseUrl: nil, viewID: 
0, p2p: false)
 }
diff --git a/TalerWallet1/Views/Main/MainView.swift 
b/TalerWallet1/Views/Main/MainView.swift
index 7743cf9..69623ad 100644
--- a/TalerWallet1/Views/Main/MainView.swift
+++ b/TalerWallet1/Views/Main/MainView.swift
@@ -33,7 +33,7 @@ struct MainView: View {
 #endif
         Group {
             if controller.backendState == .ready {
-                Content(symLog: symLog, stack: stack.push(), talerFont: 
$talerFont)
+                Content(symLog: symLog, stack: stack.push("Content"), 
talerFont: $talerFont)
                 // any change to rootViewId triggers popToRootView behaviour
                     .id(viewState.rootViewId)
                     .onAppear() {
@@ -78,14 +78,15 @@ extension MainView {
             }
         }
 
-        let balances = String(localized: "Balances")
+        let balancesTitle = String(localized: "Balances")
         let exchanges = String(localized: "Exchanges")
+        let settingsTitle = String(localized: "Settings")
         let settings = String(localized: "Settings")
         var views: [SidebarItem] {[
-            SidebarItem(name: balances,
+            SidebarItem(name: balancesTitle,
                     sysImage: "creditcard.fill",        // TODO: Wallet Icon
-                        view: AnyView(BalancesListView(stack: 
stack.push(balances),
-                                                    navTitle: balances,
+                        view: AnyView(BalancesListView(stack: 
stack.push(balancesTitle),
+                                                    navTitle: balancesTitle,
                                              hamburgerAction: hamburgerAction)
                                      )),
             SidebarItem(name: exchanges,
@@ -94,10 +95,11 @@ extension MainView {
                                                     navTitle: exchanges,
                                              hamburgerAction: hamburgerAction)
                                      )),
-            SidebarItem(name: settings,    // TODO: "About"?
+            SidebarItem(name: settingsTitle,    // TODO: "About"?
                     sysImage: "gearshape.fill",
-                        view: AnyView(SettingsView(navTitle: settings,
-                                            hamburgerAction: hamburgerAction)
+                        view: AnyView(SettingsView(stack: 
stack.push(settingsTitle),
+                                                navTitle: settingsTitle,
+                                         hamburgerAction: hamburgerAction)
                                      ))
         ]}
         @State var currentView: Int = 0
diff --git a/TalerWallet1/Views/Main/SideBarView.swift 
b/TalerWallet1/Views/Main/SideBarView.swift
index 9072542..0ae3b1d 100644
--- a/TalerWallet1/Views/Main/SideBarView.swift
+++ b/TalerWallet1/Views/Main/SideBarView.swift
@@ -97,10 +97,10 @@ struct SideBarView_Previews: PreviewProvider {
     static var views: [SidebarItem] {[
         SidebarItem(name: "Balances",
                 sysImage: "creditcard.fill",        // TODO: Wallet Icon
-                    view: AnyView(WalletEmptyView())),
+                    view: AnyView(WalletEmptyView(stack: 
CallStack("Preview")))),
         SidebarItem(name: "Settings",
                 sysImage: "gearshape.fill",
-                    view: AnyView(WalletEmptyView()))
+                    view: AnyView(WalletEmptyView(stack: 
CallStack("Preview"))))
     ]}
     static var previews: some View {
         BindingViewContainer(views: views)
diff --git a/TalerWallet1/Views/Main/WalletEmptyView.swift 
b/TalerWallet1/Views/Main/WalletEmptyView.swift
index 1e691e6..c357f03 100644
--- a/TalerWallet1/Views/Main/WalletEmptyView.swift
+++ b/TalerWallet1/Views/Main/WalletEmptyView.swift
@@ -10,6 +10,7 @@ import SymLog
 
 struct WalletEmptyView: View {
     private let symLog = SymLogV(0)
+    let stack: CallStack
     @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic
 
     var body: some View {
@@ -31,13 +32,13 @@ struct WalletEmptyView: View {
         .accessibilityFont(.title2)
         .background(WalletColors().backgroundColor.edgesIgnoringSafeArea(.all))
         .onAppear() {
-            DebugViewC.shared.setViewID(VIEW_EMPTY)     // 10
+            DebugViewC.shared.setViewID(VIEW_EMPTY, stack: 
stack.push("onAppear"))     // 10
         }
     }
 }
 
 struct WalletEmptyView_Previews: PreviewProvider {
     static var previews: some View {
-        WalletEmptyView()
+        WalletEmptyView(stack: CallStack("Preview"))
     }
 }
diff --git a/TalerWallet1/Views/Peer2peer/PaymentPurpose.swift 
b/TalerWallet1/Views/Peer2peer/PaymentPurpose.swift
index 577ecc5..339a8f6 100644
--- a/TalerWallet1/Views/Peer2peer/PaymentPurpose.swift
+++ b/TalerWallet1/Views/Peer2peer/PaymentPurpose.swift
@@ -86,7 +86,7 @@ struct PaymentPurpose: View {
         .navigationTitle("Request")
         .background(WalletColors().backgroundColor.edgesIgnoringSafeArea(.all))
         .onAppear {
-            DebugViewC.shared.setViewID(VIEW_RECEIVE_PURPOSE)
+            DebugViewC.shared.setViewID(VIEW_RECEIVE_PURPOSE, stack: 
stack.push())
             print("❗️ PaymentPurpose onAppear")
         }
         .onDisappear {
diff --git a/TalerWallet1/Views/Peer2peer/RequestPayment.swift 
b/TalerWallet1/Views/Peer2peer/RequestPayment.swift
index 3460039..028dc1c 100644
--- a/TalerWallet1/Views/Peer2peer/RequestPayment.swift
+++ b/TalerWallet1/Views/Peer2peer/RequestPayment.swift
@@ -62,7 +62,7 @@ struct RequestPayment: View {
         .background(WalletColors().backgroundColor.edgesIgnoringSafeArea(.all))
         .navigationTitle(navTitle)
         .onAppear {   // make CurrencyField show the keyboard
-            DebugViewC.shared.setViewID(VIEW_RECEIVE_P2P)
+            DebugViewC.shared.setViewID(VIEW_RECEIVE_P2P, stack: stack.push())
             symLog.log("❗️Yikes \(navTitle) onAppear")
         }
         .onDisappear {
diff --git a/TalerWallet1/Views/Peer2peer/SendAmount.swift 
b/TalerWallet1/Views/Peer2peer/SendAmount.swift
index a7475cd..5fa6693 100644
--- a/TalerWallet1/Views/Peer2peer/SendAmount.swift
+++ b/TalerWallet1/Views/Peer2peer/SendAmount.swift
@@ -75,7 +75,7 @@ struct SendAmount: View {
         .background(WalletColors().backgroundColor.edgesIgnoringSafeArea(.all))
         .navigationTitle(navTitle)
         .onAppear {   // make CurrencyField show the keyboard
-            DebugViewC.shared.setViewID(VIEW_SEND_P2P)
+            DebugViewC.shared.setViewID(VIEW_SEND_P2P, stack: stack.push())
             symLog.log("❗️Yikes SendAmount onAppear")
         }
         .onDisappear {
diff --git a/TalerWallet1/Views/Peer2peer/SendPurpose.swift 
b/TalerWallet1/Views/Peer2peer/SendPurpose.swift
index 3117450..b0c4673 100644
--- a/TalerWallet1/Views/Peer2peer/SendPurpose.swift
+++ b/TalerWallet1/Views/Peer2peer/SendPurpose.swift
@@ -103,7 +103,7 @@ struct SendPurpose: View {
         .navigationTitle("Purpose")
         .background(WalletColors().backgroundColor.edgesIgnoringSafeArea(.all))
         .onAppear {
-            DebugViewC.shared.setViewID(VIEW_SEND_PURPOSE)
+            DebugViewC.shared.setViewID(VIEW_SEND_PURPOSE, stack: stack.push())
             print("❗️ SendPurpose onAppear")
         }
         .onDisappear {
diff --git a/TalerWallet1/Views/Settings/Pending/PendingOpsListView.swift 
b/TalerWallet1/Views/Settings/Pending/PendingOpsListView.swift
index 2612eea..f16288a 100644
--- a/TalerWallet1/Views/Settings/Pending/PendingOpsListView.swift
+++ b/TalerWallet1/Views/Settings/Pending/PendingOpsListView.swift
@@ -7,6 +7,7 @@ import SymLog
 
 struct PendingOpsListView: View {
     let navTitle = String(localized: "Pending")
+    let stack: CallStack
 
     @EnvironmentObject private var model: WalletModel
 
@@ -14,7 +15,7 @@ struct PendingOpsListView: View {
 
     var body: some View {
         let reloadAction = model.getPendingOperationsM
-        Content(pendingOperations: $pendingOperations, reloadAction: 
reloadAction)
+        Content(stack: stack.push(), pendingOperations: $pendingOperations, 
reloadAction: reloadAction)
             .navigationTitle(navTitle)
             .task {
                 pendingOperations = await reloadAction()
@@ -24,6 +25,7 @@ struct PendingOpsListView: View {
 // MARK: -
 extension PendingOpsListView {
     struct Content: View {
+        let stack: CallStack
         @Binding var pendingOperations: [PendingOperation]
         var reloadAction: () async -> [PendingOperation]
         @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic
@@ -34,7 +36,7 @@ extension PendingOpsListView {
                 }
                 .listStyle(myListStyle.style).anyView
                 .onAppear() {
-                    DebugViewC.shared.setViewID(VIEW_PENDING)
+                    DebugViewC.shared.setViewID(VIEW_PENDING, stack: 
stack.push())
                 }
                 .refreshable {
                     pendingOperations = await reloadAction()
diff --git a/TalerWallet1/Views/Settings/SettingsView.swift 
b/TalerWallet1/Views/Settings/SettingsView.swift
index cf2734e..471641d 100644
--- a/TalerWallet1/Views/Settings/SettingsView.swift
+++ b/TalerWallet1/Views/Settings/SettingsView.swift
@@ -19,6 +19,7 @@ import SymLog
 
 struct SettingsView: View {
     private let symLog = SymLogV(0)
+    let stack: CallStack
     let navTitle: String
 
     @EnvironmentObject private var controller: Controller
@@ -94,12 +95,12 @@ struct SettingsView: View {
                 if diagnosticModeEnabled {
                     SettingsToggle(name: String(localized: "Developer Mode"), 
value: $developerMode,
                             description: String(localized: "More information 
intended for debugging")) {
-                        DebugViewC.shared.setViewID(VIEW_SETTINGS)
+                        DebugViewC.shared.setViewID(VIEW_SETTINGS, stack: 
stack.push())
                         withAnimation { showDevelopItems = developerMode }
                     }
                     if showDevelopItems {  // show or hide the following items
                         NavigationLink {        // whole row like in a 
tableView
-                            LazyView { PendingOpsListView() }
+                            LazyView { PendingOpsListView(stack: stack.push()) 
}
                         } label: {
                             SettingsItem(name: String(localized: "Pending 
Operations"),
                                   description: String(localized: "Exchange not 
yet ready...")) {}
@@ -252,7 +253,7 @@ struct SettingsView: View {
         .navigationBarItems(leading: HamburgerButton(action: hamburgerAction))
         .onAppear() {
             showDevelopItems = developerMode
-            DebugViewC.shared.setViewID(VIEW_SETTINGS)
+            DebugViewC.shared.setViewID(VIEW_SETTINGS, stack: stack.push())
         }
         .alert("Reset Wallet",
                isPresented: $showResetAlert,
@@ -286,7 +287,7 @@ extension Bundle {
 #if DEBUG
 struct SettingsView_Previews: PreviewProvider {
     static var previews: some View {
-        SettingsView(navTitle: "Settings") { }
+        SettingsView(stack: CallStack("Preview"), navTitle: "Settings") { }
     }
 }
 #endif
diff --git a/TalerWallet1/Views/Sheets/P2P_Sheets/P2pReceiveURIView.swift 
b/TalerWallet1/Views/Sheets/P2P_Sheets/P2pReceiveURIView.swift
index 6ff8f16..26fc4a3 100644
--- a/TalerWallet1/Views/Sheets/P2P_Sheets/P2pReceiveURIView.swift
+++ b/TalerWallet1/Views/Sheets/P2P_Sheets/P2pReceiveURIView.swift
@@ -50,9 +50,10 @@ struct P2pReceiveURIView: View {
                     .buttonStyle(TalerButtonStyle(type: .prominent))
                     .padding(.horizontal)
                 } else {
-                    ToSButtonView(exchangeBaseUrl: nil,
-                                           viewID: SHEET_RCV_P2P_TOS,
-                                              p2p: true)
+                    ToSButtonView(stack: stack.push(),
+                        exchangeBaseUrl: nil,
+                                 viewID: SHEET_RCV_P2P_TOS,
+                                    p2p: true)
                 }
             } else {
                 // Yikes no details or no baseURL
diff --git 
a/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawTOSView.swift 
b/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawTOSView.swift
index 3df21c8..bf584a5 100644
--- a/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawTOSView.swift
+++ b/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawTOSView.swift
@@ -7,6 +7,7 @@ import SymLog
 
 struct WithdrawTOSView: View {
     private let symLog = SymLogV(0)
+    let stack: CallStack
     @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic
 
     let navTitle = String(localized: "Terms of Service")
@@ -56,7 +57,7 @@ struct WithdrawTOSView: View {
             if viewID > SHEET_WITHDRAWAL {
                 DebugViewC.shared.setSheetID(SHEET_WITHDRAW_TOS)
             } else {
-                DebugViewC.shared.setViewID(VIEW_WITHDRAW_TOS)
+                DebugViewC.shared.setViewID(VIEW_WITHDRAW_TOS, stack: 
stack.push())
             }
         }.task {
             do {
diff --git 
a/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawURIView.swift 
b/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawURIView.swift
index 9388983..0dc3a9e 100644
--- a/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawURIView.swift
+++ b/TalerWallet1/Views/Sheets/WithdrawBankIntegrated/WithdrawURIView.swift
@@ -60,9 +60,10 @@ struct WithdrawURIView: View {
                     .buttonStyle(TalerButtonStyle(type: .prominent))
                     .padding(.horizontal)
                 } else {
-                    ToSButtonView(exchangeBaseUrl: exchangeBaseUrl,
-                                           viewID: SHEET_WITHDRAW_TOS,
-                                              p2p: false)
+                    ToSButtonView(stack: stack.push(),
+                        exchangeBaseUrl: exchangeBaseUrl,
+                                 viewID: SHEET_WITHDRAW_TOS,
+                                    p2p: false)
                 }
             } else {
                 // Yikes no details or no baseURL
diff --git a/TalerWallet1/Views/Transactions/TransactionDetailView.swift 
b/TalerWallet1/Views/Transactions/TransactionDetailView.swift
index e7c4a24..409b37b 100644
--- a/TalerWallet1/Views/Transactions/TransactionDetailView.swift
+++ b/TalerWallet1/Views/Transactions/TransactionDetailView.swift
@@ -158,7 +158,7 @@ struct TransactionDetailView: View {
         }
         .onAppear {
             symLog.log("onAppear")
-            DebugViewC.shared.setViewID(VIEW_TRANSACTIONDETAIL)
+            DebugViewC.shared.setViewID(VIEW_TRANSACTIONDETAIL, stack: 
stack.push())
         }
         .onDisappear {
             symLog.log("onDisappear")
diff --git a/TalerWallet1/Views/Transactions/TransactionsEmptyView.swift 
b/TalerWallet1/Views/Transactions/TransactionsEmptyView.swift
index 73dc463..1e44551 100644
--- a/TalerWallet1/Views/Transactions/TransactionsEmptyView.swift
+++ b/TalerWallet1/Views/Transactions/TransactionsEmptyView.swift
@@ -10,6 +10,7 @@ import SymLog
 
 struct TransactionsEmptyView: View {
     private let symLog = SymLogV(0)
+    let stack: CallStack
     @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic
 
     let currency: String
@@ -25,13 +26,13 @@ struct TransactionsEmptyView: View {
 //        .padding(.vertical)
         .background(WalletColors().backgroundColor.edgesIgnoringSafeArea(.all))
         .onAppear() {
-            DebugViewC.shared.setViewID(VIEW_EMPTY)     // 10
+            DebugViewC.shared.setViewID(VIEW_EMPTY, stack: stack.push())     
// 10
         }
     }
 }
 
 struct TransactionsEmptyView_Previews: PreviewProvider {
     static var previews: some View {
-        TransactionsEmptyView(currency: LONGCURRENCY)
+        TransactionsEmptyView(stack: CallStack("Preview"), currency: 
LONGCURRENCY)
     }
 }
diff --git a/TalerWallet1/Views/Transactions/TransactionsListView.swift 
b/TalerWallet1/Views/Transactions/TransactionsListView.swift
index 3548566..8322ba5 100644
--- a/TalerWallet1/Views/Transactions/TransactionsListView.swift
+++ b/TalerWallet1/Views/Transactions/TransactionsListView.swift
@@ -68,11 +68,11 @@ struct TransactionsListView: View {
         }
         .overlay {
             if transactions.isEmpty {
-                TransactionsEmptyView(currency: currency)
+                TransactionsEmptyView(stack: stack.push(), currency: currency)
             }
         }
         .onAppear {
-            DebugViewC.shared.setViewID(VIEW_TRANSACTIONLIST)
+            DebugViewC.shared.setViewID(VIEW_TRANSACTIONLIST, stack: 
stack.push())
         }
     }
 }

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]