Skip to content

Commit 3962d50

Browse files
committed
Use Android color reference for android:colorBackground in AMOLED theme
My best guess is that API 28 and below somehow interpret ``#000000`` to mean either ``@null`` or transparent for ``android:colorBackground``.
1 parent f9f37d3 commit 3962d50

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

app/src/main/res/values/themes.xml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,8 @@
138138
</style>
139139

140140
<style name="Base.Theme.Aegis.Amoled" parent="Base.Theme.Aegis.Dark">
141-
<item name="android:colorBackground">#000000</item>
141+
<!-- Setting android:colorBackground to #000000 on API 28 and below causes smearing -->
142+
<item name="android:colorBackground">@android:color/black</item>
142143
<item name="colorSurface">#000000</item>
143144
<item name="colorSurfaceVariant">#000000</item>
144145
<item name="colorSurfaceContainerHighest">#000000</item>
@@ -152,7 +153,8 @@
152153
</style>
153154

154155
<style name="ThemeOverlay.Aegis.Dynamic.Amoled" parent="ThemeOverlay.Material3.DynamicColors.Dark">
155-
<item name="android:colorBackground">#000000</item>
156+
<!-- Setting android:colorBackground to #000000 on API 28 and below causes smearing -->
157+
<item name="android:colorBackground">@android:color/black</item>
156158
<item name="colorSurface">#000000</item>
157159
<item name="colorSurfaceVariant">#000000</item>
158160
<item name="colorSurfaceContainerHighest">#000000</item>

0 commit comments

Comments
 (0)