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

Commit 6928396a authored by Chris Göllner's avatar Chris Göllner Committed by Chris Göllner
Browse files

Fix mobile icon in shade header being too large on connected displays

There are two parts to this fix:
1. The shade moves between displays, and when it happens, a
   configuration shade is triggered.
   ModernStatusBarMobileView was not updating its dimensions after this
   configuration change.
2. ModernStatusBarMobileView was using a custom Context, with a mcc and
   mnc override. The way it was done, was with a ThemeContextWrapper and
   a Configuration override. The Configuration used for the override was
   based on the base Configuration + MMC and MNC.
   This was not working together with our display aware Context, which
   gets updated whenever the shade moves between displays. With this
   approach, it would always have the display metrics of the
   initial display, and not get updated.
   The solution here is to create an empty Configuration object for the
   override, and only set the MCC and MNC. This way only MCC and MNC are
   used for the override.

Bug: 412409667
Test: ModernStatusBarMobileViewTest
Test: MobileContextProviderTest
Test: Demo mode - Mobile data and MCC and MNC values set
Flag: com.android.systemui.fix_shade_header_wrong_icon_size
Change-Id: I4e92cc8fea62403bb1b0a8e469f1b2d634aa2c15
parent ba418f68
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