diff --git a/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/SettingsView.kt b/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/SettingsView.kt index 5eb906cea8..1c4aac68f6 100644 --- a/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/SettingsView.kt +++ b/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/SettingsView.kt @@ -194,7 +194,8 @@ fun SettingsLayout( Text(annotatedStringResource(R.string.install_simplex_chat_for_terminal)) } Divider(Modifier.padding(horizontal = 8.dp)) - SettingsSectionView(showVideoChatPrototype) { +// SettingsSectionView(showVideoChatPrototype) { + SettingsSectionView() { Text("v${BuildConfig.VERSION_NAME} (${BuildConfig.VERSION_CODE})") } } diff --git a/apps/ios/Shared/AppDelegate.swift b/apps/ios/Shared/AppDelegate.swift index 2d427d20a7..415f6348f0 100644 --- a/apps/ios/Shared/AppDelegate.swift +++ b/apps/ios/Shared/AppDelegate.swift @@ -21,16 +21,17 @@ class AppDelegate: NSObject, UIApplicationDelegate { logger.debug("AppDelegate: didRegisterForRemoteNotificationsWithDeviceToken \(token)") let m = ChatModel.shared m.deviceToken = token - let useNotifications = UserDefaults.standard.bool(forKey: "useNotifications") - if useNotifications { - Task { - do { - m.tokenStatus = try await apiRegisterToken(token: token) - } catch { - logger.error("apiRegisterToken error: \(responseError(error))") - } - } - } + UserDefaults.standard.set(false, forKey: DEFAULT_USE_NOTIFICATIONS) +// let useNotifications = UserDefaults.standard.bool(forKey: "useNotifications") +// if useNotifications { +// Task { +// do { +// m.tokenStatus = try await apiRegisterToken(token: token) +// } catch { +// logger.error("apiRegisterToken error: \(responseError(error))") +// } +// } +// } } func application(_ application: UIApplication, didFailToRegisterForRemoteNotificationsWithError error: Error) { diff --git a/apps/ios/Shared/Views/Chat/ChatView.swift b/apps/ios/Shared/Views/Chat/ChatView.swift index 21fc16c5b8..f9c313863a 100644 --- a/apps/ios/Shared/Views/Chat/ChatView.swift +++ b/apps/ios/Shared/Views/Chat/ChatView.swift @@ -106,14 +106,14 @@ struct ChatView: View { ChatInfoView(chat: chat, showChatInfo: $showChatInfo) } } - ToolbarItem(placement: .navigationBarTrailing) { - if case let .direct(contact) = cInfo { - HStack { - callButton(contact, .audio, imageName: "phone") - callButton(contact, .video, imageName: "video") - } - } - } +// ToolbarItem(placement: .navigationBarTrailing) { +// if case let .direct(contact) = cInfo { +// HStack { +// callButton(contact, .audio, imageName: "phone") +// callButton(contact, .video, imageName: "video") +// } +// } +// } } .navigationBarBackButtonHidden(true) } diff --git a/apps/ios/Shared/Views/ChatList/ChatListView.swift b/apps/ios/Shared/Views/ChatList/ChatListView.swift index ff9ba5bee5..0761350b5b 100644 --- a/apps/ios/Shared/Views/ChatList/ChatListView.swift +++ b/apps/ios/Shared/Views/ChatList/ChatListView.swift @@ -14,7 +14,7 @@ struct ChatListView: View { @State private var showSettings = false @State private var searchText = "" @State private var showCallView = false - @AppStorage("pendingConnections") private var pendingConnections = true + @AppStorage(DEFAULT_PENDING_CONNECTIONS) private var pendingConnections = true var user: User diff --git a/apps/ios/Shared/Views/UserSettings/SettingsView.swift b/apps/ios/Shared/Views/UserSettings/SettingsView.swift index 996560adb4..5e716b76bb 100644 --- a/apps/ios/Shared/Views/UserSettings/SettingsView.swift +++ b/apps/ios/Shared/Views/UserSettings/SettingsView.swift @@ -14,12 +14,15 @@ let appVersion = Bundle.main.object(forInfoDictionaryKey: "CFBundleShortVersionS let appBuild = Bundle.main.object(forInfoDictionaryKey: "CFBundleVersion") as? String +let DEFAULT_USE_NOTIFICATIONS = "useNotifications" +let DEFAULT_PENDING_CONNECTIONS = "pendingConnections" + struct SettingsView: View { @Environment(\.colorScheme) var colorScheme @EnvironmentObject var chatModel: ChatModel @Binding var showSettings: Bool - @AppStorage("useNotifications") private var useNotifications = false - @AppStorage("pendingConnections") private var pendingConnections = true + @AppStorage(DEFAULT_USE_NOTIFICATIONS) private var useNotifications = false + @AppStorage(DEFAULT_PENDING_CONNECTIONS) private var pendingConnections = true @State var showNotificationsAlert: Bool = false @State var whichNotificationsAlert = NotificationAlert.enable @@ -137,12 +140,12 @@ struct SettingsView: View { .padding(.trailing, 8) Text("Install [SimpleX Chat for terminal](https://github.com/simplex-chat/simplex-chat)") } - if let token = chatModel.deviceToken { - HStack { - notificationsIcon() - notificationsToggle(token) - } - } +// if let token = chatModel.deviceToken { +// HStack { +// notificationsIcon() +// notificationsToggle(token) +// } +// } // NavigationLink { // CallViewDebug() // .frame(maxHeight: .infinity, alignment: .top)