2024-02-02 04:24:16 +05:30
|
|
|
import Defaults
|
|
|
|
import SwiftyJSON
|
|
|
|
|
|
|
|
struct AdvancedSettingsGroupImporter {
|
|
|
|
var json: JSON
|
|
|
|
|
|
|
|
func performImport() {
|
|
|
|
if let showPlayNowInBackendContextMenu = json["showPlayNowInBackendContextMenu"].bool {
|
|
|
|
Defaults[.showPlayNowInBackendContextMenu] = showPlayNowInBackendContextMenu
|
|
|
|
}
|
|
|
|
|
2024-09-10 14:34:05 +05:30
|
|
|
if let videoLoadingRetryCount = json["videoLoadingRetryCount"].int {
|
|
|
|
Defaults[.videoLoadingRetryCount] = videoLoadingRetryCount
|
|
|
|
}
|
|
|
|
|
2024-02-02 04:24:16 +05:30
|
|
|
if let showMPVPlaybackStats = json["showMPVPlaybackStats"].bool {
|
|
|
|
Defaults[.showMPVPlaybackStats] = showMPVPlaybackStats
|
|
|
|
}
|
|
|
|
|
|
|
|
if let mpvEnableLogging = json["mpvEnableLogging"].bool {
|
|
|
|
Defaults[.mpvEnableLogging] = mpvEnableLogging
|
|
|
|
}
|
|
|
|
|
|
|
|
if let mpvCacheSecs = json["mpvCacheSecs"].string {
|
|
|
|
Defaults[.mpvCacheSecs] = mpvCacheSecs
|
|
|
|
}
|
|
|
|
|
|
|
|
if let mpvCachePauseWait = json["mpvCachePauseWait"].string {
|
|
|
|
Defaults[.mpvCachePauseWait] = mpvCachePauseWait
|
|
|
|
}
|
|
|
|
|
2024-07-06 16:02:31 +05:30
|
|
|
if let mpvCachePauseInital = json["mpvCachePauseInital"].bool {
|
|
|
|
Defaults[.mpvCachePauseInital] = mpvCachePauseInital
|
|
|
|
}
|
|
|
|
|
2024-02-02 14:13:46 +05:30
|
|
|
if let mpvDeinterlace = json["mpvDeinterlace"].bool {
|
|
|
|
Defaults[.mpvDeinterlace] = mpvDeinterlace
|
|
|
|
}
|
|
|
|
|
2024-07-06 16:02:31 +05:30
|
|
|
if let mpvHWdec = json["mpvHWdec"].string {
|
|
|
|
Defaults[.mpvHWdec] = mpvHWdec
|
|
|
|
}
|
|
|
|
|
|
|
|
if let mpvDemuxerLavfProbeInfo = json["mpvDemuxerLavfProbeInfo"].string {
|
|
|
|
Defaults[.mpvDemuxerLavfProbeInfo] = mpvDemuxerLavfProbeInfo
|
|
|
|
}
|
|
|
|
|
|
|
|
if let mpvInitialAudioSync = json["mpvInitialAudioSync"].bool {
|
|
|
|
Defaults[.mpvInitialAudioSync] = mpvInitialAudioSync
|
|
|
|
}
|
|
|
|
|
2024-02-02 04:24:16 +05:30
|
|
|
if let showCacheStatus = json["showCacheStatus"].bool {
|
|
|
|
Defaults[.showCacheStatus] = showCacheStatus
|
|
|
|
}
|
|
|
|
|
|
|
|
if let feedCacheSize = json["feedCacheSize"].string {
|
|
|
|
Defaults[.feedCacheSize] = feedCacheSize
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|