mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-28 19:05:49 +00:00
Don't show Calls tab by default
This commit is contained in:
parent
764f792eb6
commit
ad3147dbbf
@ -1165,8 +1165,6 @@ final class SharedApplicationContext {
|
||||
self.registerForNotifications(context: context.context, authorize: authorizeNotifications)
|
||||
|
||||
self.resetIntentsIfNeeded(context: context.context)
|
||||
|
||||
let _ = storeCurrentCallListTabDefaultValue(accountManager: context.context.sharedContext.accountManager).start()
|
||||
}))
|
||||
} else {
|
||||
self.mainWindow.viewController = nil
|
||||
|
||||
@ -7,7 +7,7 @@ public struct CallListSettings: PreferencesEntry, Equatable {
|
||||
public var defaultShowTab: Bool?
|
||||
|
||||
public static var defaultSettings: CallListSettings {
|
||||
return CallListSettings(showTab: true)
|
||||
return CallListSettings(showTab: false)
|
||||
}
|
||||
|
||||
public var showTab: Bool {
|
||||
@ -87,17 +87,3 @@ public func updateCallListSettingsInteractively(accountManager: AccountManager,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
public func storeCurrentCallListTabDefaultValue(accountManager: AccountManager) -> Signal<Void, NoError> {
|
||||
return accountManager.transaction { transaction -> Void in
|
||||
transaction.updateSharedData(ApplicationSpecificSharedDataKeys.callListSettings, { entry in
|
||||
let currentSettings: CallListSettings
|
||||
if let entry = entry as? CallListSettings {
|
||||
currentSettings = entry
|
||||
} else {
|
||||
currentSettings = CallListSettings(showTab: nil, defaultShowTab: CallListSettings.defaultSettings.showTab)
|
||||
}
|
||||
return currentSettings
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user