mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 22:55:00 +00:00
Various Fixes
This commit is contained in:
@@ -6994,6 +6994,8 @@ Sorry for the inconvenience.";
|
||||
|
||||
"AuthSessions.View.Browser" = "Browser";
|
||||
"AuthSessions.View.Device" = "Device";
|
||||
"AuthSessions.View.Application" = "Application";
|
||||
"AuthSessions.View.OS" = "Operating System";
|
||||
"AuthSessions.View.Location" = "Location";
|
||||
"AuthSessions.View.IP" = "IP Address";
|
||||
"AuthSessions.View.TerminateSession" = "Terminate Session";
|
||||
|
||||
@@ -142,10 +142,10 @@ func iconForSession(_ session: RecentAccountSession) -> (UIImage?, String?) {
|
||||
return (UIImage(bundleImageName: "Settings/Devices/iPhone"), "device_iphone")
|
||||
}
|
||||
if device.contains("ipad") {
|
||||
return (UIImage(bundleImageName: "Settings/Devices/iPad"), nil)
|
||||
return (UIImage(bundleImageName: "Settings/Devices/iPad"), "device_ipad")
|
||||
}
|
||||
if (platform.contains("macos") || systemVersion.contains("macos")) && device.contains("mac") {
|
||||
return (UIImage(bundleImageName: "Settings/Devices/Mac"), nil)
|
||||
return (UIImage(bundleImageName: "Settings/Devices/Mac"), "device_mac")
|
||||
}
|
||||
if platform.contains("ios") || platform.contains("macos") || systemVersion.contains("macos") {
|
||||
return (UIImage(bundleImageName: "Settings/Devices/iOS"), nil)
|
||||
|
||||
@@ -253,7 +253,6 @@ private class RecentSessionScreenNode: ViewControllerTracingNode, UIScrollViewDe
|
||||
var appVersion = session.appVersion
|
||||
appVersion = appVersion.replacingOccurrences(of: "APPSTORE", with: "").replacingOccurrences(of: "BETA", with: "Beta").trimmingTrailingSpaces()
|
||||
|
||||
title = "\(session.appName) \(appVersion)"
|
||||
if session.isCurrent {
|
||||
subtitle = presentationData.strings.Presence_online
|
||||
subtitleActive = true
|
||||
@@ -261,25 +260,26 @@ private class RecentSessionScreenNode: ViewControllerTracingNode, UIScrollViewDe
|
||||
subtitle = stringForRelativeActivityTimestamp(strings: presentationData.strings, dateTimeFormat: presentationData.dateTimeFormat, relativeTimestamp: session.activityDate, relativeTo: timestamp)
|
||||
subtitleActive = false
|
||||
}
|
||||
deviceTitle = presentationData.strings.AuthSessions_View_Device
|
||||
deviceTitle = presentationData.strings.AuthSessions_View_Application
|
||||
|
||||
var deviceString = ""
|
||||
if !session.deviceModel.isEmpty {
|
||||
deviceString = session.deviceModel
|
||||
}
|
||||
if !session.platform.isEmpty {
|
||||
if !deviceString.isEmpty {
|
||||
deviceString += ", "
|
||||
}
|
||||
deviceString += session.platform
|
||||
}
|
||||
if !session.systemVersion.isEmpty {
|
||||
if !deviceString.isEmpty {
|
||||
deviceString += ", "
|
||||
}
|
||||
deviceString += session.systemVersion
|
||||
}
|
||||
device = deviceString
|
||||
// if !session.platform.isEmpty {
|
||||
// if !deviceString.isEmpty {
|
||||
// deviceString += ", "
|
||||
// }
|
||||
// deviceString += session.platform
|
||||
// }
|
||||
// if !session.systemVersion.isEmpty {
|
||||
// if !deviceString.isEmpty {
|
||||
// deviceString += ", "
|
||||
// }
|
||||
// deviceString += session.systemVersion
|
||||
// }
|
||||
title = deviceString
|
||||
device = "\(session.appName) \(appVersion)"
|
||||
location = session.country
|
||||
ip = session.ip
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user