diff options
author | Tiger Huang <tigerhuang@google.com> | 2021-07-01 22:57:35 +0800 |
---|---|---|
committer | Tiger Huang <tigerhuang@google.com> | 2021-07-01 23:25:51 +0800 |
commit | 0eb56cb3595889b46496ded1cc6532118a85ce76 (patch) | |
tree | 3b01ce53946c13a51b7c59ac212e7f698124960e /core/jni/AndroidRuntime.cpp | |
parent | 9515d87dbbdf530abfac876f0547fee27b188d0e (diff) |
Remove the light flag if the bar isn't specified light in theme
Previously, PhoneWindow will add the light flag for the bar if it is
specified light in theme. It won't remove the light flag if the theme is
not light. The previous logic in PhoneWindow#generateLayout assumes the
decor view was newly created.
However, the decor view can be reused from the preserved window. This
happens if the activity is recreated. So if the previous activity was in
a light theme and the newly created activity is in a dark theme, we
should clear the light bar flags added in the previous activity.
Fix: 174502412
Test: 1. Set Dialer (Phone) to dark theme from Dialer's display options.
2. Clear app data from Dialer's app info.
3. Open Dialer again and see if the color of system bars are
normal.
Change-Id: I3ea61322e4c3cfe26981e23792f42ab0b9a1e217
Diffstat (limited to 'core/jni/AndroidRuntime.cpp')
0 files changed, 0 insertions, 0 deletions