mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
Added Smart Invert Colors support
First take on deferred permissions request
This commit is contained in:
@@ -1,6 +1,14 @@
|
||||
import SwiftSignalKit
|
||||
import UIKit
|
||||
|
||||
func smartInvertColorsEnabled() -> Bool {
|
||||
if #available(iOSApplicationExtension 11.0, *), UIAccessibilityIsInvertColorsEnabled() {
|
||||
return true
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
func reduceMotionEnabled() -> Signal<Bool, NoError> {
|
||||
return Signal { subscriber in
|
||||
subscriber.putNext(UIAccessibility.isReduceMotionEnabled)
|
||||
|
||||
Reference in New Issue
Block a user