diff --git a/Linphone/GeneratedGit.swift b/Linphone/GeneratedGit.swift index 0fb82505a..fd2930164 100644 --- a/Linphone/GeneratedGit.swift +++ b/Linphone/GeneratedGit.swift @@ -2,6 +2,6 @@ import Foundation public enum AppGitInfo { public static let branch = "master" - public static let commit = "5bbbbe5d7" + public static let commit = "ca9f5ffe1" public static let tag = "6.1.0-alpha" } diff --git a/Linphone/UI/Main/ContentView.swift b/Linphone/UI/Main/ContentView.swift index 7e160ad17..da1e3c584 100644 --- a/Linphone/UI/Main/ContentView.swift +++ b/Linphone/UI/Main/ContentView.swift @@ -598,65 +598,37 @@ struct ContentView: View { } .padding(.trailing, sharedMainViewModel.indexView == 2 ? 10 : 0) - if sharedMainViewModel.indexView == 3 { - Button { - NotificationCenter.default.post(name: MeetingsListViewModel.ScrollToTodayNotification, object: nil) - } label: { - Image("calendar") - .renderingMode(.template) - .resizable() - .foregroundStyle(.white) - .frame(width: 25, height: 25, alignment: .leading) - .padding(.all, 10) - } - .padding(.trailing, 10) - } else if sharedMainViewModel.indexView != 2 { + if sharedMainViewModel.indexView == 0 { Menu { - if sharedMainViewModel.indexView == 0 { - Button { - sharedMainViewModel.displayedFriend = nil - isMenuOpen = false - magicSearch.changeAllContact(allContactBool: true) - magicSearch.searchForContacts() - } label: { - HStack { - Text("contacts_list_filter_popup_see_all") - Spacer() - if magicSearch.allContact { - Image("green-check") - .resizable() - .frame(width: 25, height: 25, alignment: .leading) - .padding(.all, 10) - } + Button { + sharedMainViewModel.displayedFriend = nil + isMenuOpen = false + magicSearch.changeAllContact(allContactBool: true) + magicSearch.searchForContacts() + } label: { + HStack { + Text("contacts_list_filter_popup_see_all") + Spacer() + if magicSearch.allContact { + Image("green-check") + .resizable() + .frame(width: 25, height: 25, alignment: .leading) + .padding(.all, 10) } } - - Button { - sharedMainViewModel.displayedFriend = nil - isMenuOpen = false - magicSearch.changeAllContact(allContactBool: false) - magicSearch.searchForContacts() - } label: { - HStack { - Text(!magicSearch.linphoneDomain ? String(localized: "contacts_list_filter_popup_see_sip_only") : String(format: String(localized: "contacts_list_filter_popup_see_linphone_only"), Bundle.main.displayName)) - Spacer() - if !magicSearch.allContact { - Image("green-check") - .resizable() - .frame(width: 25, height: 25, alignment: .leading) - .padding(.all, 10) - } - } - } - } else { - Button(role: .destructive) { - isMenuOpen = false - isShowDeleteAllHistoryPopup.toggle() - } label: { - HStack { - Text("menu_delete_history") - Spacer() - Image("trash-simple-red") + } + + Button { + sharedMainViewModel.displayedFriend = nil + isMenuOpen = false + magicSearch.changeAllContact(allContactBool: false) + magicSearch.searchForContacts() + } label: { + HStack { + Text(!magicSearch.linphoneDomain ? String(localized: "contacts_list_filter_popup_see_sip_only") : String(format: String(localized: "contacts_list_filter_popup_see_linphone_only"), Bundle.main.displayName)) + Spacer() + if !magicSearch.allContact { + Image("green-check") .resizable() .frame(width: 25, height: 25, alignment: .leading) .padding(.all, 10) @@ -675,6 +647,30 @@ struct ContentView: View { .onTapGesture { isMenuOpen = true } + } else if sharedMainViewModel.indexView == 1 { + Button { + isShowDeleteAllHistoryPopup.toggle() + } label: { + Image("trash-simple") + .renderingMode(.template) + .resizable() + .foregroundStyle(.white) + .frame(width: 25, height: 25, alignment: .leading) + .padding(.all, 10) + } + .padding(.trailing, 10) + } else if sharedMainViewModel.indexView == 3 { + Button { + NotificationCenter.default.post(name: MeetingsListViewModel.ScrollToTodayNotification, object: nil) + } label: { + Image("calendar") + .renderingMode(.template) + .resizable() + .foregroundStyle(.white) + .frame(width: 25, height: 25, alignment: .leading) + .padding(.all, 10) + } + .padding(.trailing, 10) } } .frame(maxWidth: .infinity) diff --git a/Linphone/UI/Main/Fragments/SideMenuAccountRow.swift b/Linphone/UI/Main/Fragments/SideMenuAccountRow.swift index 9679e0cd5..a691477c2 100644 --- a/Linphone/UI/Main/Fragments/SideMenuAccountRow.swift +++ b/Linphone/UI/Main/Fragments/SideMenuAccountRow.swift @@ -137,26 +137,27 @@ struct SideMenuAccountRow: View { .padding(.trailing, -8) } - Menu { - Button { - accountProfileViewModel.accountModelIndex = CoreContext.shared.accounts.firstIndex(where: {$0.displayName == model.displayName}) - withAnimation { - isOpen = false - isShowAccountProfileFragment = true - } - } label: { - Label("drawer_menu_manage_account", systemImage: "arrow.right.circle") + Button { + accountProfileViewModel.accountModelIndex = CoreContext.shared.accounts.firstIndex(where: {$0.displayName == model.displayName}) + withAnimation { + isOpen = false + isShowAccountProfileFragment = true } } label: { - VStack { - Image("dots-three-vertical") - .renderingMode(.template) - .resizable() - .foregroundColor(Color.grayMain2c500) - .scaledToFit() - .frame(height: 25) + Image("user-circle-gear") + .renderingMode(.template) + .resizable() + .foregroundColor(Color.grayMain2c600) + .scaledToFit() + .frame(height: 25) + } + .frame(width: 30, height: 30) + .onTapGesture { + accountProfileViewModel.accountModelIndex = CoreContext.shared.accounts.firstIndex(where: {$0.displayName == model.displayName}) + withAnimation { + isOpen = false + isShowAccountProfileFragment = true } - .frame(width: 30, height: 30) } } .frame(alignment: .trailing)