PubSpec中的飘动暗模式飞溅屏幕设置
我为我的飞溅屏幕使用软件包splash_screen_view
。 它为该应用程序的默认主题提供了深色和轻度的图像。 但是,如果用户主题手机很轻,并且想使用该应用程序Dark,那么如何为飞溅设置条件呢? 此软件包的设置设置在pubspec.yaml
中
,请有人帮助我吗?
I use package splash_screen_view
for my splash screen.
and it got the dark and light image for the default theme of the app.
but if the user theme mobile is light and wants to use the app dark, how can I set a condition for my splash?
the setting of this package sets In pubspec.yaml
so can anyone help me, please?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
检查您的材料App()是否具有主题和DarkTheme设置并设置thememode:thememode.system,因此您的应用程序遵循用户手机的设置。
看起来像这样:
SplashScreen将遵循正确的设置。
奖励:搜索 flutter_native_splash 也将本机SplashColor设置为PhoneSetting。
Check that your MaterialApp() has theme and darkTheme set AND set themeMode: ThemeMode.system, so your app follows the settings of the user's phone.
Looks something like this:
Your splashscreen will follow the correct setting.
Bonus: Search for flutter_native_splash to ALSO set the native splashcolor to phonesetting.