Skip to content

Commit

Permalink
fix: wrong window being shown when an invitations gets accepted
Browse files Browse the repository at this point in the history
  • Loading branch information
davide-baldo committed Nov 8, 2023
1 parent 541c0f8 commit 739124d
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions implementations/swift/ockam/ockam_app/Ockam/OckamApp.swift
Original file line number Diff line number Diff line change
Expand Up @@ -80,17 +80,19 @@ struct OckamApp: App {
.menuBarExtraStyle(.window)
.commandsRemoved()

Window("Could not load local state", id: "broken-state") {
BrokenStateView()
}
.windowResizability(.contentSize)

// Declare a window with an empty view to handle the ockam:// url
// A hack to overcome the fact that `onOpenURL` only works on `Windows`
Window("Accepting invitation", id: "accepting-invitation") {
OpenUrlView(enrolled: $state.enrolled)
}
.windowResizability(.contentSize)

// Declare a window being shown when the ockam state cannot be loadeds
Window("Could not load local state", id: "broken-state") {
BrokenStateView()
}
.windowResizability(.contentSize)

// Declare a state-independent window, not open by default
Window("Create an outlet to a tcp service", id: "create-service") {
CreateServiceView()
Expand Down

0 comments on commit 739124d

Please sign in to comment.