How can I change Status Bar Alpha in iOS 13?

前端 未结 3 2104
悲哀的现实
悲哀的现实 2020-12-18 07:25

I want to change the Status Bar Alpha in iOS 13.

let statusBarWindow = UIApplication.shared.value(forKey: \"statusBarWindow\") as? UIWindow
statusBarWindow?.         


        
3条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-18 07:48

    The status bar is rendered by a system process (out of the app process) on iOS 13 so there is no way for an app to change this. (Source: speaking to UIKit engineers at the WWDC 2019 labs.)

    You can see this in the Apple Books app, which used to dim the status bar in its dark mode on iOS 12, but this does not happen on iOS 13.

提交回复
热议问题