mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 02:58:07 +00:00
Update defaultAccount on logout
This commit is contained in:
parent
737a9880b6
commit
4b87be84bd
2 changed files with 11 additions and 2 deletions
|
|
@ -460,8 +460,11 @@ struct ContentView: View {
|
|||
cachedImage
|
||||
.resizable()
|
||||
.aspectRatio(contentMode: .fill)
|
||||
.frame(width: avatarSize, height: avatarSize)
|
||||
.clipShape(Circle())
|
||||
.frame(width: avatarSize, height: avatarSize)
|
||||
.clipShape(Circle())
|
||||
.onTapGesture {
|
||||
openMenu()
|
||||
}
|
||||
} else {
|
||||
ProgressView()
|
||||
.frame(width: avatarSize, height: avatarSize)
|
||||
|
|
|
|||
|
|
@ -641,6 +641,12 @@ struct AccountProfileFragment: View {
|
|||
actionSecondButton: {
|
||||
if accountProfileViewModel.accountModelIndex != nil {
|
||||
CoreContext.shared.accounts[accountProfileViewModel.accountModelIndex!].logout()
|
||||
isShowAccountProfileFragment = false
|
||||
if let firstAccount = CoreContext.shared.accounts.first?.account {
|
||||
CoreContext.shared.doOnCoreQueue { core in
|
||||
core.defaultAccount = firstAccount
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue