Skip to content

Commit

Permalink
Fix lint overdraw warning
Browse files Browse the repository at this point in the history
Turns out you're supposed to set the background on the app theme to null if you want to make sure that dynamic colors are applied in a way that avoids potential overdraw.
  • Loading branch information
t895 committed Sep 8, 2024
1 parent 6cf2668 commit 8a7ba5e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 0 additions & 1 deletion app/src/main/res/layout/activity_attestation.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?attr/colorSurface"
tools:context="app.attestation.auditor.AttestationActivity">

<com.google.android.material.appbar.AppBarLayout
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
<item name="colorSurfaceContainer">@color/grapheneSurfaceContainerColor</item>

<item name="popupMenuStyle">@style/GraphenePopup</item>

<item name="background">@null</item>
</style>

<style name="GraphenePopup" parent="Widget.Material3.PopupMenu">
Expand Down

0 comments on commit 8a7ba5e

Please sign in to comment.