Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f09692bf authored by Adam Bookatz's avatar Adam Bookatz
Browse files

Only check phoneStatusBarIcon if profile

We currently request getUserStatusBarIconResId very frequently. We only
need to do so if it is a profile, since all non-profiles have no status
bar icon anyway, nor should they. Indeed, the method calling this is
called updateProfileIcon(). Fixing this has two advantages:
* We log a warning each time we ask for a non-profile's icon, so this
will clear up logcat.
* isProfile() gets automatically cached, whereas phoneStatusBarIcon
doesn't, so this will be more efficient, since we'll bypass the call
whenever it's not a profile.

Test: atest SystemUITests:com.android.systemui.statusbar.phone.PhoneStatusBarPolicyTest
Flag: EXEMPT bugfix
Change-Id: Ic12606975a96f44c9ee62b1ec200255bd0e5620c
parent 441143d1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment