|
|
@ -28,14 +28,14 @@ class TimezoneData: NSObject, NSCoding { |
|
|
|
|
|
|
|
|
|
|
|
enum TimezoneOverride: Int { |
|
|
|
enum TimezoneOverride: Int { |
|
|
|
case globalFormat = 0 |
|
|
|
case globalFormat = 0 |
|
|
|
case twelveHourFormat |
|
|
|
case twelveHourFormat = 1 |
|
|
|
case twentyFourFormat |
|
|
|
case twentyFourFormat = 2 |
|
|
|
case twelveHourWithSeconds |
|
|
|
case twelveHourWithSeconds = 4 |
|
|
|
case twentyHourWithSeconds |
|
|
|
case twentyHourWithSeconds = 5 |
|
|
|
case twelveHourPrecedingZero |
|
|
|
case twelveHourPrecedingZero = 7 |
|
|
|
case twelveHourPrecedingZeroSeconds |
|
|
|
case twelveHourPrecedingZeroSeconds = 8 |
|
|
|
case twelveHourWithoutSuffix |
|
|
|
case twelveHourWithoutSuffix = 10 |
|
|
|
case twelveHourWithoutSuffixAndSeconds |
|
|
|
case twelveHourWithoutSuffixAndSeconds = 11 |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
static let values = [ |
|
|
|
static let values = [ |
|
|
@ -335,6 +335,7 @@ class TimezoneData: NSObject, NSCoding { |
|
|
|
} else if shouldOverride == 4 { |
|
|
|
} else if shouldOverride == 4 { |
|
|
|
overrideFormat = .twelveHourWithSeconds |
|
|
|
overrideFormat = .twelveHourWithSeconds |
|
|
|
} else if shouldOverride == 5 { |
|
|
|
} else if shouldOverride == 5 { |
|
|
|
|
|
|
|
print("Setting override format to five") |
|
|
|
overrideFormat = .twentyHourWithSeconds |
|
|
|
overrideFormat = .twentyHourWithSeconds |
|
|
|
} else if shouldOverride == 7 { |
|
|
|
} else if shouldOverride == 7 { |
|
|
|
overrideFormat = .twelveHourPrecedingZero |
|
|
|
overrideFormat = .twelveHourPrecedingZero |
|
|
@ -344,6 +345,8 @@ class TimezoneData: NSObject, NSCoding { |
|
|
|
overrideFormat = .twelveHourWithoutSuffix |
|
|
|
overrideFormat = .twelveHourWithoutSuffix |
|
|
|
} else if shouldOverride == 11 { |
|
|
|
} else if shouldOverride == 11 { |
|
|
|
overrideFormat = .twelveHourWithoutSuffixAndSeconds |
|
|
|
overrideFormat = .twelveHourWithoutSuffixAndSeconds |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
assertionFailure("Chosen a wrong timezone format") |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|