mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-15 18:59:54 +00:00
Initialize MediaAutoDownloadNetworkType with NetworkType
This commit is contained in:
parent
2e81229d8a
commit
0bdce8a93b
@ -10,6 +10,17 @@ public enum MediaAutoDownloadNetworkType {
|
||||
case cellular
|
||||
}
|
||||
|
||||
public extension MediaAutoDownloadNetworkType {
|
||||
init(_ networkType: NetworkType) {
|
||||
switch networkType {
|
||||
case .none, .cellular:
|
||||
self = .cellular
|
||||
case .wifi:
|
||||
self = .wifi
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public enum MediaAutoDownloadPreset: Int32 {
|
||||
case low
|
||||
case medium
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user