Flutter项目在iOS下禁用暗黑模式

在iOS项目的plist里添加如下配置

1.设置View controller-based status bar appearance

在info.plist文件中 View controller-based status bar appearance
->Boolean-> YES,则控制器对状态栏设置的优先级高于app
->Boolean-> NO,则以app为准,控制器设置状态栏设置无效

2.设置User Interface Style

在info.plist文件中 User Interface Style
->String-> Light,则app禁用暗黑模式,APP默认支持暗黑模式

3.info.plist

有图有真相
info

猜你喜欢

转载自blog.csdn.net/gjm_123/article/details/107730527