The app starts with status bar color:
Background white, the text is black.
When entering modal pop up screen, status bar changes to back, with white text:
window?.setStatusBarColor(Color.BLACK);
activity?.window?.decorView?.systemUiVisibility = SYSTEM_UI_FLAG_LIGHT_NAVIGATION_BAR
Works!
Next, on modal popup screen dismiss, I would like the status bar to go back to normal:
background white, and black text
with no luck.
What did I try? This:
window?.setStatusBarColor(Color.BLACK); // This really does work
activity?.window?.decorView?.systemUiVisibility = // Not sure what should be the value
Status bar background does change, but not text. Not sure what systemUiVisibility value should be.
Read https://developer.android.com/reference/android/view/View But didn't find anything suitable, tried
SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN, SYSTEM_UI_FLAG_LAYOUT_STABLE
Still no luck.