Open DavidCorrado opened 6 years ago
still waiting..
The black status bar is still reproducible on the latest master 1.24.0-8.0.pre.291
.
This is further complicated by issues like https://github.com/flutter/flutter/issues/39614, https://github.com/flutter/flutter/issues/65405, and https://github.com/flutter/flutter/issues/61149.
I can still reproduce this issue on Android 11. On Android 13 for example, the status bar is white by default. Updating labels to reflect the same
Short Summary of issue It seems that the app launch process does not handle themes properly and does not theme the status bar and background color correctly per how you would expect if you were developing natively on Android
Additonal Details So from my testing there is two basic app launch scenarios a native app should use to launch the app per the material documentation: https://material.io/design/communication/launch-screen.html#usage Basically a splash screen and placeholder UI. I saw there are are many pull requests related to this such as: https://github.com/flutter/flutter/issues/8147 https://github.com/flutter/flutter/pull/11505
It seems that on iOS it works how I would expect but on Android I would expect it to use the theme on launch to make it feel more native.
Below is how it works on Native Android: Android Native With Splash Note: Shows status bar per the theme. Android Native Without Splash: Note: Shows status bar per the theme.
Steps to reproduce If I create the default flutter android application per Android Studio and below is my flutter doctor results
I am testing on a Pixel 2 Emulator API 26
There are 3 situations I would like to highlight with examples 1) Default flutter app with no modifications looks like below: Note: Status bar changes from Black to the themed blue
2) Flutter app with splash modified to match theme color Note: Status bar changes from Black to themed blue
3) Flutter app with splash disabled Note: Screen is black and then goes into themed app
Goal state It would be great if there was a way to first of all get the theme you choose in flutter to plug into android like you included it via a style. Also with the solution you might want to consider how to support more placeholder UI such as I want to show the toolbar on app launch or something like that.
Work around https://github.com/DavidCorrado/FlutterSplashTesting/commit/9aa6861e64fffe52d0138e19ce7be79ed75caaed